Rename TEST_MODE to specific variable for CodeQL Action
This allows us to set it automatically in the workflow generator, simplifying things and reducing the scope for error.
This commit is contained in:
parent
c939e6615d
commit
a190d3876a
70 changed files with 51 additions and 245 deletions
|
|
@ -8,3 +8,6 @@ export const CODEQL_WORKFLOW_STARTED_AT = "CODEQL_WORKFLOW_STARTED_AT";
|
|||
|
||||
export const CODEQL_ACTION_TESTING_ENVIRONMENT =
|
||||
"CODEQL_ACTION_TESTING_ENVIRONMENT";
|
||||
|
||||
/** Used to disable uploading SARIF results or status reports to the GitHub API */
|
||||
export const CODEQL_ACTION_TEST_MODE = "CODEQL_ACTION_TEST_MODE";
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ import {
|
|||
import { Feature, FeatureEnablement } from "./feature-flags";
|
||||
import { Language } from "./languages";
|
||||
import { Logger } from "./logging";
|
||||
import { CODEQL_ACTION_TEST_MODE } from "./shared-environment";
|
||||
|
||||
/**
|
||||
* Specifies bundle versions that are known to be broken
|
||||
|
|
@ -664,7 +665,7 @@ export async function checkActionVersion(version: string) {
|
|||
* In test mode, we don't upload SARIF results or status reports to the GitHub API.
|
||||
*/
|
||||
export function isInTestMode(): boolean {
|
||||
return process.env["TEST_MODE"] === "true";
|
||||
return process.env[CODEQL_ACTION_TEST_MODE] === "true";
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue