From e430bdb0d4d6fe9b6638070da2a115103ca092f7 Mon Sep 17 00:00:00 2001 From: Saad Jutt Date: Sat, 2 Apr 2022 05:51:24 +0500 Subject: [PATCH] test(upload): spec updated for file upload exceeding limit --- api/src/routes/api/spec/drive.spec.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/src/routes/api/spec/drive.spec.ts b/api/src/routes/api/spec/drive.spec.ts index 7f65069..ec054d1 100644 --- a/api/src/routes/api/spec/drive.spec.ts +++ b/api/src/routes/api/spec/drive.spec.ts @@ -425,7 +425,7 @@ describe('drive', () => { it('should respond with Bad Request if attached file exceeds file limit', async () => { const pathToUpload = '/my/path/code.sas' - const attachedFile = Buffer.from('.'.repeat(20 * 1024 * 1024)) + const attachedFile = Buffer.from('.'.repeat(110 * 1024 * 1024)) // 110mb const res = await request(app) .post('/SASjsApi/drive/file') @@ -435,7 +435,7 @@ describe('drive', () => { .expect(400) expect(res.text).toEqual( - 'File size is over limit. File limit is: 10 MB' + 'File size is over limit. File limit is: 100 MB' ) expect(res.body).toEqual({}) })