test: test RUNNER_TOOL_CACHE in cache tests

This commit is contained in:
Amin Yahyaabadi 2022-01-30 17:58:01 -08:00
parent b43302cf75
commit 6d9651573c
4 changed files with 4 additions and 4 deletions

View File

@ -19,7 +19,7 @@ describe("setup-cmake", () => {
const { binDir } = await setupCmake("3.20.2", directory, process.arch)
await testBin("cmake", ["--version"], binDir)
if (isGitHubCI()) {
expect(binDir).toMatch("hostedtoolcache")
expect(binDir).toMatch(process.env.RUNNER_TOOL_CACHE ?? "hostedtoolcache")
}
})

View File

@ -55,7 +55,7 @@ describe("setup-llvm", () => {
await testBin("clang++", ["--version"], binDir)
if (isGitHubCI()) {
expect(binDir).toMatch("hostedtoolcache")
expect(binDir).toMatch(process.env.RUNNER_TOOL_CACHE ?? "hostedtoolcache")
}
expect(process.env.CC?.includes("clang")).toBeTruthy()

View File

@ -22,7 +22,7 @@ describe("setup-ninja", () => {
it("should find Ninja in the cache", async () => {
const binDir = await testNinja(directory)
if (isGitHubCI()) {
expect(binDir).toMatch("hostedtoolcache")
expect(binDir).toMatch(process.env.RUNNER_TOOL_CACHE ?? "hostedtoolcache")
}
})

View File

@ -18,7 +18,7 @@ describe("setup-task", () => {
it("should find task in the cache", async () => {
const { binDir } = await setupTask("3.10.0", directory, process.arch)
if (isGitHubCI()) {
expect(binDir).toMatch("hostedtoolcache")
expect(binDir).toMatch(process.env.RUNNER_TOOL_CACHE ?? "hostedtoolcache")
}
})