tests: added tests

This commit is contained in:
GitHub Actions
2021-01-16 22:41:34 +01:00
parent bf0785847d
commit b8890fc6d7
7 changed files with 240 additions and 12 deletions

View File

@@ -6,8 +6,7 @@ import * as exec from '@actions/exec';
const { GITHUB_REPOSITORY, GITHUB_REF } = process.env;
const branch = GITHUB_REF?.replace('refs/heads/', '');
export default new (class Git {
class Git {
constructor() {
const githubToken = core.getInput('github-token', { required: true });
core.setSecret(githubToken);
@@ -80,4 +79,6 @@ export default new (class Git {
updateOrigin = (repo: string) => this.exec(`remote set-url origin ${repo}`);
createTag = (tag: string) => this.exec(`tag -a ${tag} -m "${tag}"`);
})();
}
export default new Git();

View File

@@ -3,6 +3,7 @@
* https://github.com/jhermsmeier/node-http-link-header
*/
/* istanbul ignore file */
'use strict';
var COMPATIBLE_ENCODING_PATTERN = /^utf-?8|ascii|utf-?16-?le|ucs-?2|base-?64|latin-?1$/i;