--- a/tests/src/setConstOnChainSchema.test.ts +++ b/tests/src/setConstOnChainSchema.test.ts @@ -26,7 +26,7 @@ }); }); -describe('Integration Test ext. setConstOnChainSchema()', () => { +describe.only('Integration Test ext. setConstOnChainSchema()', () => { it('Run extrinsic with parameters of the collection id, set the scheme', async () => { await usingApi(async (api) => { @@ -36,7 +36,7 @@ const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await submitTransactionAsync(Alice, setShema); }); -}); + }); it('Checking collection data using the ConstOnChainSchema parameter', async () => { await usingApi(async (api) => { @@ -50,7 +50,7 @@ }); }); -describe('Negative Integration Test ext. setConstOnChainSchema()', () => { +describe.only('Negative Integration Test ext. setConstOnChainSchema()', () => { it('Set a non-existent collection', async () => { await usingApi(async (api) => { @@ -58,8 +58,8 @@ const collectionId = parseInt((await api.query.nft.createdCollectionCount()).toString()) + 1; const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await expect(submitTransactionExpectFailAsync(Alice, setShema)).to.be.rejected; + }); }); -}); it('Set a previously deleted collection', async () => { await usingApi(async (api) => { @@ -67,16 +67,16 @@ await destroyCollectionExpectSuccess(collectionId); const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await expect(submitTransactionExpectFailAsync(Alice, setShema)).to.be.rejected; + }); }); -}); it('Set invalid data in schema (size too large:> 1024b)', async () => { await usingApi(async (api) => { const collectionId = await createCollectionExpectSuccess(); const setShema = api.tx.nft.setConstOnChainSchema(collectionId, largeShema); await expect(submitTransactionExpectFailAsync(Alice, setShema)).to.be.rejected; + }); }); -}); it('Execute method not on behalf of the collection owner', async () => { await usingApi(async (api) => { @@ -85,7 +85,7 @@ expect(collection.Owner.toString()).to.be.eq(Alice.address); const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await expect(submitTransactionExpectFailAsync(Bob, setShema)).to.be.rejected; + }); }); -}); });