From b6b4ad113e7da66bbfd7fe97f9d5499e06457ec8 Mon Sep 17 00:00:00 2001 From: str-mv Date: Thu, 15 Jul 2021 13:56:46 +0000 Subject: [PATCH] Integration tests setConstOnChainSchema and setVariableOnChainSchema fixed --- --- a/tests/src/change-collection-owner.test.ts +++ b/tests/src/change-collection-owner.test.ts @@ -12,7 +12,7 @@ chai.use(chaiAsPromised); const expect = chai.expect; -describe.only('Integration Test changeCollectionOwner(collection_id, new_owner):', () => { +describe('Integration Test changeCollectionOwner(collection_id, new_owner):', () => { it('Changing owner changes owner address', async () => { await usingApi(async api => { const collectionId = await createCollectionExpectSuccess(); @@ -31,7 +31,7 @@ }); }); -describe.only('Negative Integration Test changeCollectionOwner(collection_id, new_owner):', () => { +describe('Negative Integration Test changeCollectionOwner(collection_id, new_owner):', () => { it('Not owner can\'t change owner.', async () => { await usingApi(async api => { const collectionId = await createCollectionExpectSuccess(); --- a/tests/src/eth/nonFungible.test.ts +++ b/tests/src/eth/nonFungible.test.ts @@ -61,7 +61,7 @@ }); }); -describe.only('Plain calls', () => { +describe('Plain calls', () => { itWeb3('Can perform approve()', async ({ web3, api }) => { const collection = await createCollectionExpectSuccess({ mode: { type: 'NFT' }, --- a/tests/src/setConstOnChainSchema.test.ts +++ b/tests/src/setConstOnChainSchema.test.ts @@ -38,7 +38,7 @@ await usingApi(async (api) => { const collectionId = await createCollectionExpectSuccess(); const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON(); - expect(collection.Owner).to.be.deep.eq(normalizeAccountId(Alice.address)); + expect(collection.Owner).to.be.eq(Alice.address); const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await submitTransactionAsync(Alice, setShema); }); @@ -88,7 +88,7 @@ await usingApi(async (api) => { const collectionId = await createCollectionExpectSuccess(); const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON(); - expect(collection.Owner).to.be.deep.eq(normalizeAccountId(Alice.address)); + expect(collection.Owner).to.be.eq(Alice.address); const setShema = api.tx.nft.setConstOnChainSchema(collectionId, Shema); await expect(submitTransactionExpectFailAsync(Bob, setShema)).to.be.rejected; }); --- a/tests/src/setVariableOnChainSchema.test.ts +++ b/tests/src/setVariableOnChainSchema.test.ts @@ -38,7 +38,7 @@ await usingApi(async (api) => { const collectionId = await createCollectionExpectSuccess(); const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON(); - expect(collection.Owner).to.be.deep.eq(normalizeAccountId(Alice.address)); + expect(collection.Owner).to.be.eq(Alice.address); const setSchema = api.tx.nft.setVariableOnChainSchema(collectionId, Schema); await submitTransactionAsync(Alice, setSchema); }); @@ -88,7 +88,7 @@ await usingApi(async (api) => { const collectionId = await createCollectionExpectSuccess(); const collection: any = (await api.query.nft.collectionById(collectionId)).toJSON(); - expect(collection.Owner).to.be.deep.eq(normalizeAccountId(Alice.address)); + expect(collection.Owner).to.be.eq(Alice.address); const setSchema = api.tx.nft.setVariableOnChainSchema(collectionId, Schema); await expect(submitTransactionExpectFailAsync(Bob, setSchema)).to.be.rejected; }); -- gitstuff