mirror of
https://git.mirrors.martin98.com/https://github.com/actions/toolkit
synced 2026-05-04 10:28:05 +08:00
Use Azure storage SDK to download cache (#497)
* Adds option to download using AzCopy * Bump version number and add release notes * Ensure we use at least v10 * Negate env var so it disables AzCopy * Use Azure storage SDK to download cache * Use same level of parallelism as AzCopy * Fix naming of variable * React to feedback * Bump Node types to Node 12 * Make linter happy * Pass options into restoreCache method * Fix tests * Restructure files and add tests * Add method to get the default download and upload options * Include breaking changes in RELEASES.md Co-authored-by: Josh Gross <joshmgross@github.com>
This commit is contained in:
8
packages/cache/__tests__/cacheUtils.test.ts
vendored
8
packages/cache/__tests__/cacheUtils.test.ts
vendored
@@ -24,3 +24,11 @@ test('unlinkFile unlinks file', async () => {
|
||||
|
||||
await fs.rmdir(testDirectory)
|
||||
})
|
||||
|
||||
test('assertDefined throws if undefined', () => {
|
||||
expect(() => cacheUtils.assertDefined('test', undefined)).toThrowError()
|
||||
})
|
||||
|
||||
test('assertDefined returns value', () => {
|
||||
expect(cacheUtils.assertDefined('test', 5)).toBe(5)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user