mirror of
https://github.com/game-ci/unity-builder.git
synced 2025-07-07 20:35:33 -04:00
cleanup async parameter
This commit is contained in:
parent
df4cc41418
commit
e296ef2dc1
@ -1,22 +1,11 @@
|
||||
{
|
||||
"plugins": [
|
||||
"jest",
|
||||
"@typescript-eslint",
|
||||
"prettier",
|
||||
"unicorn"
|
||||
],
|
||||
"extends": [
|
||||
"plugin:unicorn/recommended",
|
||||
"plugin:github/recommended",
|
||||
"plugin:prettier/recommended"
|
||||
],
|
||||
"plugins": ["jest", "@typescript-eslint", "prettier", "unicorn"],
|
||||
"extends": ["plugin:unicorn/recommended", "plugin:github/recommended", "plugin:prettier/recommended"],
|
||||
"parser": "@typescript-eslint/parser",
|
||||
"parserOptions": {
|
||||
"ecmaVersion": 2020,
|
||||
"sourceType": "module",
|
||||
"extraFileExtensions": [
|
||||
".mjs"
|
||||
],
|
||||
"extraFileExtensions": [".mjs"],
|
||||
"ecmaFeatures": {
|
||||
"impliedStrict": true
|
||||
},
|
||||
@ -33,10 +22,7 @@
|
||||
// Namespaces or sometimes needed
|
||||
"import/no-namespace": "off",
|
||||
// Properly format comments
|
||||
"spaced-comment": [
|
||||
"error",
|
||||
"always"
|
||||
],
|
||||
"spaced-comment": ["error", "always"],
|
||||
"lines-around-comment": [
|
||||
"error",
|
||||
{
|
||||
@ -71,12 +57,7 @@
|
||||
// Enforce camelCase
|
||||
"camelcase": "error",
|
||||
// Allow forOfStatements
|
||||
"no-restricted-syntax": [
|
||||
"error",
|
||||
"ForInStatement",
|
||||
"LabeledStatement",
|
||||
"WithStatement"
|
||||
],
|
||||
"no-restricted-syntax": ["error", "ForInStatement", "LabeledStatement", "WithStatement"],
|
||||
// Continue is viable in forOf loops in generators
|
||||
"no-continue": "off",
|
||||
// From experience, named exports are almost always desired. I got tired of this rule
|
||||
|
BIN
dist/index.js
generated
vendored
BIN
dist/index.js
generated
vendored
Binary file not shown.
BIN
dist/index.js.map
generated
vendored
BIN
dist/index.js.map
generated
vendored
Binary file not shown.
@ -39,11 +39,11 @@ describe('Cloud Runner Github Checks', () => {
|
||||
asyncCloudRunner: `true`,
|
||||
githubChecks: `true`,
|
||||
});
|
||||
GitHub.asyncWorkflows = true;
|
||||
GitHub.forceAsyncTest = true;
|
||||
await CloudRunner.setup(buildParameter);
|
||||
CloudRunner.buildParameters.githubCheckId = await GitHub.createGitHubCheck(`t`);
|
||||
await GitHub.updateGitHubCheck(`t`, `t2`);
|
||||
GitHub.asyncWorkflows = false;
|
||||
GitHub.forceAsyncTest = false;
|
||||
}, 1_000_000_000);
|
||||
}
|
||||
});
|
||||
|
@ -11,7 +11,7 @@ class GitHub {
|
||||
private static startedDate: string;
|
||||
private static endedDate: string;
|
||||
static result: string = ``;
|
||||
static asyncWorkflows: boolean;
|
||||
static forceAsyncTest: boolean;
|
||||
private static get octokitDefaultToken() {
|
||||
return new Octokit({
|
||||
auth: process.env.GITHUB_TOKEN,
|
||||
@ -128,7 +128,7 @@ class GitHub {
|
||||
data.conclusion = result;
|
||||
}
|
||||
|
||||
await (CloudRunner.isCloudRunnerAsyncEnvironment || GitHub.asyncWorkflows
|
||||
await (CloudRunner.isCloudRunnerAsyncEnvironment || GitHub.forceAsyncTest
|
||||
? GitHub.runUpdateAsyncChecksWorkflow(data, `update`)
|
||||
: GitHub.updateGitHubCheckRequest(data));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user