import cli methods
parent
df84273a78
commit
d66e085008
|
|
@ -41,7 +41,7 @@ describe('Cloud Runner Caching', () => {
|
||||||
fs.writeFileSync(path.resolve(testFolder, 'test.txt'), CLI.options.cacheKey);
|
fs.writeFileSync(path.resolve(testFolder, 'test.txt'), CLI.options.cacheKey);
|
||||||
await Caching.PushToCache(cacheFolder, testFolder, `${CLI.options.cacheKey}.zip`);
|
await Caching.PushToCache(cacheFolder, testFolder, `${CLI.options.cacheKey}.zip`);
|
||||||
// delete test folder
|
// delete test folder
|
||||||
fs.rmdirSync(testFolder);
|
fs.rmdirSync(testFolder, { recursive: true });
|
||||||
await Caching.PullFromCache(
|
await Caching.PullFromCache(
|
||||||
cacheFolder.replace(/\\/g, `/`),
|
cacheFolder.replace(/\\/g, `/`),
|
||||||
testFolder.replace(/\\/g, `/`),
|
testFolder.replace(/\\/g, `/`),
|
||||||
|
|
@ -49,8 +49,8 @@ describe('Cloud Runner Caching', () => {
|
||||||
);
|
);
|
||||||
// compare validity to original hash
|
// compare validity to original hash
|
||||||
expect(fs.readFileSync(path.resolve(testFolder, 'test.txt'))).toContain(CLI.options.cacheKey);
|
expect(fs.readFileSync(path.resolve(testFolder, 'test.txt'))).toContain(CLI.options.cacheKey);
|
||||||
fs.rmdirSync(testFolder);
|
fs.rmdirSync(testFolder, { recursive: true });
|
||||||
fs.rmdirSync(cacheFolder);
|
fs.rmdirSync(cacheFolder, { recursive: true });
|
||||||
|
|
||||||
Input.githubInputEnabled = true;
|
Input.githubInputEnabled = true;
|
||||||
delete CLI.options;
|
delete CLI.options;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue