diff --git a/lib/codeql.test.js b/lib/codeql.test.js index a01ce90493..88585ca9e5 100644 --- a/lib/codeql.test.js +++ b/lib/codeql.test.js @@ -237,7 +237,7 @@ for (const toolcacheVersion of [ t.is(cachedVersions.length, 2); }); }); -(0, ava_1.default)('downloads bundle if "latest" tools specified but not cached', async (t) => { +(0, ava_1.default)('downloads bundle if "linked" tools specified but not cached', async (t) => { await util.withTmpDir(async (tmpDir) => { (0, testing_utils_1.setupActionsVars)(tmpDir, tmpDir); await installIntoToolcache({ @@ -248,7 +248,7 @@ for (const toolcacheVersion of [ (0, testing_utils_1.mockBundleDownloadApi)({ tagName: defaults.bundleVersion, }); - const result = await codeql.setupCodeQL("latest", testing_utils_1.SAMPLE_DOTCOM_API_DETAILS, tmpDir, util.GitHubVariant.DOTCOM, testing_utils_1.SAMPLE_DEFAULT_CLI_VERSION, (0, logging_1.getRunnerLogger)(true), false); + const result = await codeql.setupCodeQL("linked", testing_utils_1.SAMPLE_DOTCOM_API_DETAILS, tmpDir, util.GitHubVariant.DOTCOM, testing_utils_1.SAMPLE_DEFAULT_CLI_VERSION, (0, logging_1.getRunnerLogger)(true), false); t.deepEqual(result.toolsVersion, defaults.cliVersion); t.is(result.toolsSource, setup_codeql_1.ToolsSource.Download); t.assert(Number.isInteger(result.toolsDownloadDurationMs)); diff --git a/lib/setup-codeql.test.js b/lib/setup-codeql.test.js index f630cdac67..ab5464f1f0 100644 --- a/lib/setup-codeql.test.js +++ b/lib/setup-codeql.test.js @@ -92,12 +92,12 @@ ava_1.default.beforeEach(() => { t.is(source.sourceType, "download"); }); }); -(0, ava_1.default)("getCodeQLSource correctly returns bundled CLI version when tools == latest", async (t) => { +(0, ava_1.default)("getCodeQLSource correctly returns bundled CLI version when tools == linked", async (t) => { const loggedMessages = []; const logger = (0, testing_utils_1.getRecordingLogger)(loggedMessages); await (0, util_1.withTmpDir)(async (tmpDir) => { (0, testing_utils_1.setupActionsVars)(tmpDir, tmpDir); - const source = await setupCodeql.getCodeQLSource("latest", testing_utils_1.SAMPLE_DEFAULT_CLI_VERSION, testing_utils_1.SAMPLE_DOTCOM_API_DETAILS, util_1.GitHubVariant.DOTCOM, logger); + const source = await setupCodeql.getCodeQLSource("linked", testing_utils_1.SAMPLE_DEFAULT_CLI_VERSION, testing_utils_1.SAMPLE_DOTCOM_API_DETAILS, util_1.GitHubVariant.DOTCOM, logger); // First, ensure that the CLI version is the linked version, so that backwards // compatibility is maintained. t.is(source.toolsVersion, testing_utils_1.LINKED_CLI_VERSION.cliVersion); diff --git a/src/codeql.test.ts b/src/codeql.test.ts index bfc1298ca6..ea6664a3f5 100644 --- a/src/codeql.test.ts +++ b/src/codeql.test.ts @@ -347,7 +347,7 @@ test(`downloads bundle if only an unpinned version is cached on GHES`, async (t) }); }); -test('downloads bundle if "latest" tools specified but not cached', async (t) => { +test('downloads bundle if "linked" tools specified but not cached', async (t) => { await util.withTmpDir(async (tmpDir) => { setupActionsVars(tmpDir, tmpDir); @@ -361,7 +361,7 @@ test('downloads bundle if "latest" tools specified but not cached', async (t) => tagName: defaults.bundleVersion, }); const result = await codeql.setupCodeQL( - "latest", + "linked", SAMPLE_DOTCOM_API_DETAILS, tmpDir, util.GitHubVariant.DOTCOM, diff --git a/src/setup-codeql.test.ts b/src/setup-codeql.test.ts index 1220122bf0..4a0e42d136 100644 --- a/src/setup-codeql.test.ts +++ b/src/setup-codeql.test.ts @@ -113,14 +113,14 @@ test("getCodeQLSource correctly returns bundled CLI version when tools == linked }); }); -test("getCodeQLSource correctly returns bundled CLI version when tools == latest", async (t) => { +test("getCodeQLSource correctly returns bundled CLI version when tools == linked", async (t) => { const loggedMessages: LoggedMessage[] = []; const logger = getRecordingLogger(loggedMessages); await withTmpDir(async (tmpDir) => { setupActionsVars(tmpDir, tmpDir); const source = await setupCodeql.getCodeQLSource( - "latest", + "linked", SAMPLE_DEFAULT_CLI_VERSION, SAMPLE_DOTCOM_API_DETAILS, GitHubVariant.DOTCOM,