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