🐛 Fixed bug with downloading zip folder (#541)

* 🐛Fixed bug with downloading zip folder
* ♻️Removed unused method
This commit is contained in:
Anton Shepilov
2024-05-28 13:41:11 +02:00
committed by GitHub
parent 8f75c04fdd
commit 16b39561ae
7 changed files with 29 additions and 13 deletions
@@ -106,6 +106,22 @@ describe("the Drive feature", () => {
expect(updateItemResult.name).toEqual("somethingelse");
});
it("Download folder as a zip should work fine", async () => {
//given
const folder = await currentUser.createDirectory("user_" + currentUser.user.id)
await currentUser.uploadRandomFileAndCreateDocument(folder.id);
//when
const zipResponse = await currentUser.zipDocument(folder.id);
//then
expect(zipResponse).toBeTruthy();
expect(zipResponse.statusCode).toBe(200);
//and data is in place
expect(zipResponse.body.length).toBeGreaterThanOrEqual(100);
});
it("did move an item to trash", async () => {
const createItemResult = await currentUser.createDefaultDocument();
@@ -286,7 +286,7 @@ describe("the public links feature", () => {
anotherUser.jwt = token.value;
await anotherUser.getDocumentOKCheck(doc.id);
expect((await anotherUser.getFolder(doc.id)).statusCode).toBe(200);
expect((await anotherUser.zipDocument(doc.id)).statusCode).toBe(200);
});
});
});