test: update key in tests
This commit is contained in:
parent
13a76d3742
commit
8f55f6c3be
|
@ -50,7 +50,7 @@ describe('cache-restore tests', () => {
|
|||
|
||||
await restoreCache(lockFilePattern);
|
||||
|
||||
const expectedKey = `dotnet-cache-${process.env.RUNNER_OS}-hash`;
|
||||
const expectedKey = `dotnet-cache-${process.env.RUNNER_OS}-${process.arch}-hash`;
|
||||
expect(jest.mocked(core.saveState)).toHaveBeenCalledWith(
|
||||
'CACHE_KEY',
|
||||
expectedKey
|
||||
|
@ -66,7 +66,7 @@ describe('cache-restore tests', () => {
|
|||
});
|
||||
|
||||
it('calls core.saveState("CACHE_RESULT") when cache.restoreCache() returns key', async () => {
|
||||
const expectedKey = `dotnet-cache-${process.env.RUNNER_OS}-hash`;
|
||||
const expectedKey = `dotnet-cache-${process.env.RUNNER_OS}-${process.arch}-hash`;
|
||||
jest.mocked(glob.hashFiles).mockResolvedValue('hash');
|
||||
jest.mocked(cache.restoreCache).mockResolvedValue(expectedKey);
|
||||
|
||||
|
|
|
@ -327,6 +327,10 @@ get_machine_architecture() {
|
|||
echo "loongarch64"
|
||||
return 0
|
||||
;;
|
||||
riscv64)
|
||||
echo "riscv64"
|
||||
return 0
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue