Merge pull request #1374 from github/henrymercer/pass-testing-environment
Set testing environment for CodeQL workflow
This commit is contained in:
commit
0f07790b74
72 changed files with 56 additions and 277 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