1
0
Fork 0
mirror of https://github.com/actions/toolkit synced 2025-05-09 16:43:02 +00:00

Resolved comments

This commit is contained in:
Apple 2022-04-01 01:41:12 +05:30
parent 3abbc6c24c
commit 6cd8286138
5 changed files with 27 additions and 19 deletions

View file

@ -63,17 +63,16 @@ test('save with large cache outputs should fail', async () => {
const reserveCacheMock = jest
.spyOn(cacheHttpClient, 'reserveCache')
.mockImplementation(async () => {
const response: ITypedResponseWithErrorMessage<ReserveCacheResponse> = {
const response: ITypedResponse<ReserveCacheResponse> = {
statusCode: 400,
result: null,
headers: {},
typeKey: 'InvalidReserveCacheRequestException'
headers: {}
}
return response
})
await expect(saveCache([filePath], primaryKey)).rejects.toThrowError(
'Cache size of ~11264 MB (11811160064 B) is over the data cap limit, not saving cache.'
'Cache size of ~11264 MB (11811160064 B) is over the 10GB limit, not saving cache.'
)
const archiveFolder = '/foo/bar'
@ -94,7 +93,7 @@ test('save with reserve cache failure should fail', async () => {
const reserveCacheMock = jest
.spyOn(cacheHttpClient, 'reserveCache')
.mockImplementation(async () => {
const response: ITypedResponseWithErrorMessage<ReserveCacheResponse> = {
const response: ITypedResponse<ReserveCacheResponse> = {
statusCode: 500,
result: null,
headers: {}