difftreelog
test add missing awaits
in: master
2 files changed
tests/src/collision-tests/adminLimitsOff.test.tsdiffbeforeafterboth53 ]);53 ]);54 await timeoutPromise(10000);54 await timeoutPromise(10000);55 const changeAdminTx4 = api.tx.nft.addCollectionAdmin(collectionId, Alice.address);55 const changeAdminTx4 = api.tx.nft.addCollectionAdmin(collectionId, Alice.address);56 // tslint:disable-next-line: no-unused-expression57 expect(submitTransactionExpectFailAsync(Alice, changeAdminTx4)).to.be.rejected;56 await expect(submitTransactionExpectFailAsync(Alice, changeAdminTx4)).to.be.rejected;585759 const adminListAfterAddAdmin: any = (await api.query.nft.adminList(collectionId));58 const adminListAfterAddAdmin: any = (await api.query.nft.adminList(collectionId));60 expect(adminListAfterAddAdmin).to.be.contains(Eve.address);59 expect(adminListAfterAddAdmin).to.be.contains(Eve.address);tests/src/createCollection.test.tsdiffbeforeafterboth--- a/tests/src/createCollection.test.ts
+++ b/tests/src/createCollection.test.ts
@@ -40,8 +40,7 @@
const badTransaction = async () => {
await createCollectionExpectSuccess({mode: {type: 'Invalid'}});
};
- // tslint:disable-next-line:no-unused-expression
- expect(badTransaction()).to.be.rejected;
+ await expect(badTransaction()).to.be.rejected;
const BcollectionCount = parseInt((await api.query.nft.createdCollectionCount()).toString(), 10);
expect(BcollectionCount).to.be.equal(AcollectionCount, 'Error: Incorrect collection created.');