mirror of
https://github.com/actions/cache.git
synced 2025-04-22 03:56:45 +00:00
Initial pass at chunked upload apis
This commit is contained in:
parent
e223b0a12d
commit
805d58ac4b
5 changed files with 150 additions and 42 deletions
|
@ -194,7 +194,7 @@ test("save with large cache outputs warning", async () => {
|
|||
|
||||
const createTarMock = jest.spyOn(tar, "createTar");
|
||||
|
||||
const cacheSize = 1024 * 1024 * 1024; //~1GB, over the 400MB limit
|
||||
const cacheSize = 4 * 1024 * 1024 * 1024; //~4GB, over the 2GB limit
|
||||
jest.spyOn(actionUtils, "getArchiveFileSize").mockImplementationOnce(() => {
|
||||
return cacheSize;
|
||||
});
|
||||
|
@ -208,7 +208,7 @@ test("save with large cache outputs warning", async () => {
|
|||
|
||||
expect(logWarningMock).toHaveBeenCalledTimes(1);
|
||||
expect(logWarningMock).toHaveBeenCalledWith(
|
||||
"Cache size of ~1024 MB (1073741824 B) is over the 400MB limit, not saving cache."
|
||||
"Cache size of ~4 GB (4294967296 B) is over the 2GB limit, not saving cache."
|
||||
);
|
||||
|
||||
expect(failedMock).toHaveBeenCalledTimes(0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue