difftreelog
CORE-325 Fir PR
in: master
2 files changed
tests/src/eth/collectionSponsoring.test.tsdiffbeforeafterboth1import privateKey from '../substrate/privateKey';2import {addToAllowListExpectSuccess, confirmSponsorshipExpectSuccess, createCollectionExpectSuccess, enablePublicMintingExpectSuccess, setCollectionSponsorExpectSuccess} from '../util/helpers';3import {itWeb3, transferBalanceToEth, subToEth, createEthAccount, collectionIdToAddress, GAS_ARGS, normalizeEvents} from './util/helpers';4import nonFungibleAbi from './nonFungibleAbi.json';5import {expect} from 'chai';67describe('evm collection sponsoring', () => {8 itWeb3('sponsors mint transactions', async ({api, web3}) => {9 const alice = privateKey('//Alice');1011 const collection = await createCollectionExpectSuccess();12 await setCollectionSponsorExpectSuccess(collection, alice.address);13 await confirmSponsorshipExpectSuccess(collection);1415 // Wouldn't be needed after CORE-30016 await transferBalanceToEth(api, alice, subToEth(alice.address));1718 const minter = createEthAccount(web3);19 expect(await web3.eth.getBalance(minter)).to.equal('0');2021 const address = collectionIdToAddress(collection);22 const contract = new web3.eth.Contract(nonFungibleAbi as any, collectionIdToAddress(collection), {from: minter, ...GAS_ARGS});2324 await enablePublicMintingExpectSuccess(alice, collection);25 await addToAllowListExpectSuccess(alice, collection, {Ethereum: minter});2627 const nextTokenId = await contract.methods.nextTokenId().call();28 expect(nextTokenId).to.equal('1');29 const result = await contract.methods.mint(minter, nextTokenId).send();30 const events = normalizeEvents(result.events);31 expect(events).to.be.deep.equal([32 {33 address,34 event: 'Transfer',35 args: {36 from: '0x0000000000000000000000000000000000000000',37 to: minter,38 tokenId: nextTokenId,39 },40 },41 ]);42 });43});1import privateKey from '../substrate/privateKey';2import {addToAllowListExpectSuccess, confirmSponsorshipExpectSuccess, createCollectionExpectSuccess, enablePublicMintingExpectSuccess, setCollectionSponsorExpectSuccess} from '../util/helpers';3import {itWeb3, createEthAccount, collectionIdToAddress, GAS_ARGS, normalizeEvents} from './util/helpers';4import nonFungibleAbi from './nonFungibleAbi.json';5import {expect} from 'chai';67describe('evm collection sponsoring', () => {8 itWeb3('sponsors mint transactions', async ({web3}) => {9 const alice = privateKey('//Alice');1011 const collection = await createCollectionExpectSuccess();12 await setCollectionSponsorExpectSuccess(collection, alice.address);13 await confirmSponsorshipExpectSuccess(collection);1415 const minter = createEthAccount(web3);16 expect(await web3.eth.getBalance(minter)).to.equal('0');1718 const address = collectionIdToAddress(collection);19 const contract = new web3.eth.Contract(nonFungibleAbi as any, collectionIdToAddress(collection), {from: minter, ...GAS_ARGS});2021 await enablePublicMintingExpectSuccess(alice, collection);22 await addToAllowListExpectSuccess(alice, collection, {Ethereum: minter});2324 const nextTokenId = await contract.methods.nextTokenId().call();25 expect(nextTokenId).to.equal('1');26 const result = await contract.methods.mint(minter, nextTokenId).send();27 const events = normalizeEvents(result.events);28 expect(events).to.be.deep.equal([29 {30 address,31 event: 'Transfer',32 args: {33 from: '0x0000000000000000000000000000000000000000',34 to: minter,35 tokenId: nextTokenId,36 },37 },38 ]);39 });40});tests/src/eth/metadata.test.tsdiffbeforeafterboth--- a/tests/src/eth/metadata.test.ts
+++ b/tests/src/eth/metadata.test.ts
@@ -67,7 +67,7 @@
});
});
-describe.only('Support ERC721Metadata', () => {
+describe('Support ERC721Metadata', () => {
itWeb3('Check unsupport ERC721Metadata ShemaVersion::Unique', async ({web3, api}) => {
const collectionId = await createCollectionExpectSuccess({
mode: {type: 'NFT'},