Actions status report: Send testing_environment.
The testing environment is taken from the environment variable CODEQL_ACTION_TESTING_ENVIRONMENT.
This commit is contained in:
parent
7e2585030f
commit
4b73c4f99e
3 changed files with 12 additions and 1 deletions
2
lib/actions-util.js
generated
2
lib/actions-util.js
generated
|
|
@ -502,6 +502,7 @@ async function createStatusReportBase(actionName, status, actionStartedAt, cause
|
||||||
const runnerOs = (0, util_1.getRequiredEnvParam)("RUNNER_OS");
|
const runnerOs = (0, util_1.getRequiredEnvParam)("RUNNER_OS");
|
||||||
const codeQlCliVersion = (0, util_1.getCachedCodeQlVersion)();
|
const codeQlCliVersion = (0, util_1.getCachedCodeQlVersion)();
|
||||||
const actionRef = process.env["GITHUB_ACTION_REF"];
|
const actionRef = process.env["GITHUB_ACTION_REF"];
|
||||||
|
const testingEnvironment = process.env["CODEQL_ACTION_TESTING_ENVIRONMENT"] || "";
|
||||||
const statusReport = {
|
const statusReport = {
|
||||||
workflow_run_id: workflowRunID,
|
workflow_run_id: workflowRunID,
|
||||||
workflow_name: workflowName,
|
workflow_name: workflowName,
|
||||||
|
|
@ -515,6 +516,7 @@ async function createStatusReportBase(actionName, status, actionStartedAt, cause
|
||||||
started_at: workflowStartedAt,
|
started_at: workflowStartedAt,
|
||||||
action_started_at: actionStartedAt.toISOString(),
|
action_started_at: actionStartedAt.toISOString(),
|
||||||
status,
|
status,
|
||||||
|
testing_environment: testingEnvironment,
|
||||||
runner_os: runnerOs,
|
runner_os: runnerOs,
|
||||||
action_version: pkg.version,
|
action_version: pkg.version,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -600,6 +600,12 @@ export interface StatusReportBase {
|
||||||
completed_at?: string;
|
completed_at?: string;
|
||||||
/** State this action is currently in. */
|
/** State this action is currently in. */
|
||||||
status: ActionStatus;
|
status: ActionStatus;
|
||||||
|
/**
|
||||||
|
* Testing environment: Set if non-production environment.
|
||||||
|
* The server accepts one of the following values:
|
||||||
|
* ["", "qa-rc", "qa-rc-1", "qa-rc-2", "qa-experiment-1", "qa-experiment-2", "qa-experiment-3"].
|
||||||
|
*/
|
||||||
|
testing_environment: string;
|
||||||
/**
|
/**
|
||||||
* Information about the enablement of the ML-powered JS query pack.
|
* Information about the enablement of the ML-powered JS query pack.
|
||||||
*
|
*
|
||||||
|
|
@ -675,6 +681,8 @@ export async function createStatusReportBase(
|
||||||
const runnerOs = getRequiredEnvParam("RUNNER_OS");
|
const runnerOs = getRequiredEnvParam("RUNNER_OS");
|
||||||
const codeQlCliVersion = getCachedCodeQlVersion();
|
const codeQlCliVersion = getCachedCodeQlVersion();
|
||||||
const actionRef = process.env["GITHUB_ACTION_REF"];
|
const actionRef = process.env["GITHUB_ACTION_REF"];
|
||||||
|
const testingEnvironment =
|
||||||
|
process.env["CODEQL_ACTION_TESTING_ENVIRONMENT"] || "";
|
||||||
|
|
||||||
const statusReport: StatusReportBase = {
|
const statusReport: StatusReportBase = {
|
||||||
workflow_run_id: workflowRunID,
|
workflow_run_id: workflowRunID,
|
||||||
|
|
@ -689,6 +697,7 @@ export async function createStatusReportBase(
|
||||||
started_at: workflowStartedAt,
|
started_at: workflowStartedAt,
|
||||||
action_started_at: actionStartedAt.toISOString(),
|
action_started_at: actionStartedAt.toISOString(),
|
||||||
status,
|
status,
|
||||||
|
testing_environment: testingEnvironment,
|
||||||
runner_os: runnerOs,
|
runner_os: runnerOs,
|
||||||
action_version: pkg.version,
|
action_version: pkg.version,
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue