difftreelog
fix test - wait next block
in: master
7 files changed
tests/src/check-event/burnItemEvent.test.tsdiffbeforeafterboth32 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});32 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});33 const token = await collection.mintToken(alice, {Substrate: alice.address});33 const token = await collection.mintToken(alice, {Substrate: alice.address});34 await token.burn(alice);34 await token.burn(alice);35 await helper.wait.newBlocks(1);353636 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];37 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];37 const eventStrings = event.map(e => `${e.section}.${e.method}`);38 const eventStrings = event.map(e => `${e.section}.${e.method}`);tests/src/check-event/createCollectionEvent.test.tsdiffbeforeafterboth29 });29 });30 itSub('Check event from createCollection(): ', async ({helper}) => {30 itSub('Check event from createCollection(): ', async ({helper}) => {31 await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});31 await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});32 await helper.wait.newBlocks(1);32 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];33 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];33 const eventStrings = event.map(e => `${e.section}.${e.method}`);34 const eventStrings = event.map(e => `${e.section}.${e.method}`);3435tests/src/check-event/createItemEvent.test.tsdiffbeforeafterboth30 itSub('Check event from createItem(): ', async ({helper}) => {30 itSub('Check event from createItem(): ', async ({helper}) => {31 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});31 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});32 await collection.mintToken(alice, {Substrate: alice.address});32 await collection.mintToken(alice, {Substrate: alice.address});33 await helper.wait.newBlocks(1);33 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];34 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];34 const eventStrings = event.map(e => `${e.section}.${e.method}`);35 const eventStrings = event.map(e => `${e.section}.${e.method}`);3536tests/src/check-event/createMultipleItemsEvent.test.tsdiffbeforeafterboth35 {owner: {Substrate: alice.address}},35 {owner: {Substrate: alice.address}},36 ]);36 ]);373738 await helper.wait.newBlocks(1);38 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];39 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];39 const eventStrings = event.map(e => `${e.section}.${e.method}`);40 const eventStrings = event.map(e => `${e.section}.${e.method}`);4041tests/src/check-event/destroyCollectionEvent.test.tsdiffbeforeafterboth31 itSub('Check event from destroyCollection(): ', async ({helper}) => {31 itSub('Check event from destroyCollection(): ', async ({helper}) => {32 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});32 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});33 await collection.burn(alice);33 await collection.burn(alice);34 await helper.wait.newBlocks(1);34 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];35 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];35 const eventStrings = event.map(e => `${e.section}.${e.method}`);36 const eventStrings = event.map(e => `${e.section}.${e.method}`);3637tests/src/check-event/transferEvent.test.tsdiffbeforeafterboth34 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});34 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});35 const token = await collection.mintToken(alice, {Substrate: alice.address});35 const token = await collection.mintToken(alice, {Substrate: alice.address});36 await token.transfer(alice, {Substrate: bob.address});36 await token.transfer(alice, {Substrate: bob.address});37 await helper.wait.newBlocks(1);37 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];38 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];38 const eventStrings = event.map(e => `${e.section}.${e.method}`);39 const eventStrings = event.map(e => `${e.section}.${e.method}`);3940tests/src/check-event/transferFromEvent.test.tsdiffbeforeafterboth33 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});33 const collection = await helper.nft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});34 const token = await collection.mintToken(alice, {Substrate: alice.address});34 const token = await collection.mintToken(alice, {Substrate: alice.address});35 await token.transferFrom(alice, {Substrate: alice.address}, {Substrate: bob.address});35 await token.transferFrom(alice, {Substrate: alice.address}, {Substrate: bob.address});36 await helper.wait.newBlocks(1);36 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];37 const event = helper.chainLog[helper.chainLog.length - 1].events as IEvent[];37 const eventStrings = event.map(e => `${e.section}.${e.method}`);38 const eventStrings = event.map(e => `${e.section}.${e.method}`);3839