Skip to content

Commit 6066b01

Browse files
authored
Added wait to versions test (#422)
1 parent 142a452 commit 6066b01

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

test/integration/api/admin/api_spec.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -988,6 +988,7 @@ describe("api", function () {
988988

989989
it('should restore different versions of a deleted asset', async function () {
990990
this.timeout(TIMEOUT.LARGE);
991+
991992
// Upload the same file twice (upload->delete->upload->delete)
992993

993994
// Upload and delete a file
@@ -1002,7 +1003,7 @@ describe("api", function () {
10021003
await wait(1000)();
10031004

10041005
const secondDelete = await API_V2.delete_resources([PUBLIC_ID_BACKUP_1]);
1005-
1006+
await wait(1000)();
10061007

10071008
// Sanity, ensure these uploads are different before we continue
10081009
expect(firstUpload.bytes).not.to.equal(secondUpload.bytes);
@@ -1027,6 +1028,7 @@ describe("api", function () {
10271028
expect(firstVerRestore[PUBLIC_ID_BACKUP_1].bytes).to.eql(firstUpload.bytes);
10281029

10291030
// Restore second version, ensure it's equal to the upload size
1031+
await wait(1000)();
10301032
const secondVerRestore = await API_V2.restore([PUBLIC_ID_BACKUP_1], { versions: [secondAssetVersion] });
10311033
expect(secondVerRestore[PUBLIC_ID_BACKUP_1].bytes).to.eql(secondUpload.bytes);
10321034

0 commit comments

Comments
 (0)