difftreelog
tests: update tests for storage changes
in: master
1 file changed
tests/src/createCollection.test.tsdiffbeforeafterboth35describe('(!negative test!) integration test: ext. createCollection():', () => {
35describe('(!negative test!) integration test: ext. createCollection():', () => {36 it('(!negative test!) create new NFT collection whith incorrect data (mode)', async () => {
36 it('(!negative test!) create new NFT collection whith incorrect data (mode)', async () => {37 await usingApi(async (api) => {
37 await usingApi(async (api) => {38 const AcollectionCount = parseInt((await api.query.nft.collectionCount()).toString(), 10);
38 const AcollectionCount = parseInt((await api.query.nft.createdCollectionCount()).toString(), 10);39
3940 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-expression
43 // tslint:disable-next-line:no-unused-expression44 expect(badTransaction()).to.be.rejected;
44 expect(badTransaction()).to.be.rejected;45
4546 const BcollectionCount = parseInt((await api.query.nft.collectionCount()).toString(), 10);
46 const BcollectionCount = parseInt((await api.query.nft.createdCollectionCount()).toString(), 10);47 expect(BcollectionCount).to.be.equal(AcollectionCount, 'Error: Incorrect collection created.');
47 expect(BcollectionCount).to.be.equal(AcollectionCount, 'Error: Incorrect collection created.');48 });
48 });49 });
49 });