difftreelog
Combine refungible tests
in: master
9 files changed
tests/src/burnItem.test.tsdiffbeforeafterboth46 expect(await collection.getBalance({Substrate: alice.address})).to.eq(9n);46 expect(await collection.getBalance({Substrate: alice.address})).to.eq(9n);47 });47 });4849 itSub.ifWithPallets('Burn item in ReFungible collection', [Pallets.ReFungible], async function({helper}) {50 const collection = await helper.rft.mintCollection(alice);51 const token = await collection.mintToken(alice, 100n);5253 await token.burn(alice, 90n);54 expect(await token.getBalance({Substrate: alice.address})).to.eq(10n);5556 await token.burn(alice, 10n);57 expect(await token.getBalance({Substrate: alice.address})).to.eq(0n);58 });5960 itSub.ifWithPallets('Burn owned portion of item in ReFungible collection', [Pallets.ReFungible], async function({helper}) {61 const collection = await helper.rft.mintCollection(alice);62 const token = await collection.mintToken(alice, 100n);6364 await token.transfer(alice, {Substrate: bob.address}, 1n);6566 expect(await token.getBalance({Substrate: alice.address})).to.eq(99n);67 expect(await token.getBalance({Substrate: bob.address})).to.eq(1n);6869 await token.burn(bob, 1n);7071 expect(await token.getBalance({Substrate: alice.address})).to.eq(99n);72 expect(await token.getBalance({Substrate: bob.address})).to.eq(0n);73 });74});48});754976describe('integration test: ext. burnItem() with admin permissions:', () => {50describe('integration test: ext. burnItem() with admin permissions:', () => {105 expect(await collection.getBalance({Substrate: alice.address})).to.eq(9n);79 expect(await collection.getBalance({Substrate: alice.address})).to.eq(9n);106 });80 });107108 itSub.ifWithPallets('Burn item in ReFungible collection', [Pallets.ReFungible], async function({helper}) {109 const collection = await helper.rft.mintCollection(alice);110 await collection.setLimits(alice, {ownerCanTransfer: true});111 await collection.addAdmin(alice, {Substrate: bob.address});112 const token = await collection.mintToken(alice, 100n);113114 await token.burnFrom(bob, {Substrate: alice.address}, 100n);115 expect(await token.doesExist()).to.be.false;116 });117});81});11882119describe('Negative integration test: ext. burnItem():', () => {83describe('Negative integration test: ext. burnItem():', () => {140 await expect(token.burn(bob)).to.be.rejectedWith('common.NoPermission');104 await expect(token.burn(bob)).to.be.rejectedWith('common.NoPermission');141 });105 });142143 itSub.ifWithPallets('RFT: cannot burn non-owned token pieces', [Pallets.ReFungible], async ({helper}) => {144 const collection = await helper.rft.mintCollection(alice);145 const aliceToken = await collection.mintToken(alice, 10n, {Substrate: alice.address});146 const bobToken = await collection.mintToken(alice, 10n, {Substrate: bob.address});147148 // 1. Cannot burn non-owned token:149 await expect(bobToken.burn(alice, 0n)).to.be.rejectedWith('common.TokenValueTooLow');150 await expect(bobToken.burn(alice, 5n)).to.be.rejectedWith('common.TokenValueTooLow');151 // 2. Cannot burn non-existing token:152 await expect(helper.rft.burnToken(alice, 99999, 10)).to.be.rejectedWith('common.CollectionNotFound');153 await expect(helper.rft.burnToken(alice, collection.collectionId, 99999)).to.be.rejectedWith('common.TokenValueTooLow');154 // 3. Can burn zero amount of owned tokens (EIP-20)155 await aliceToken.burn(alice, 0n);156157 // 4. Storage is not corrupted:158 expect(await aliceToken.getTop10Owners()).to.deep.eq([{Substrate: alice.address}]);159 expect(await bobToken.getTop10Owners()).to.deep.eq([{Substrate: bob.address}]);160161 // 4.1 Tokens can be transfered:162 await aliceToken.transfer(alice, {Substrate: bob.address}, 10n);163 await bobToken.transfer(bob, {Substrate: alice.address}, 10n);164 expect(await aliceToken.getTop10Owners()).to.deep.eq([{Substrate: bob.address}]);165 expect(await bobToken.getTop10Owners()).to.deep.eq([{Substrate: alice.address}]);166 });167106168 itSub('Transfer a burned token', async ({helper}) => {107 itSub('Transfer a burned token', async ({helper}) => {169 const collection = await helper.nft.mintCollection(alice);108 const collection = await helper.nft.mintCollection(alice);tests/src/eth/createNFTCollection.test.tsdiffbeforeafterboth434344 expect(events).to.be.deep.equal([44 expect(events).to.be.deep.equal([45 {45 {46 address: COLLECTION_HELPER,46 address: '0x6C4E9fE1AE37a41E93CEE429e8E1881aBdcbb54F',47 event: 'CollectionCreated',47 event: 'CollectionCreated',48 args: {48 args: {49 owner: owner,49 owner: owner,tests/src/nesting/nest.test.tsdiffbeforeafterboth15// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.15// along with Unique Network. If not, see <http://www.gnu.org/licenses/>.161617import {IKeyringPair} from '@polkadot/types/types';17import {IKeyringPair} from '@polkadot/types/types';18import {expect, itSub, Pallets, usingPlaygrounds} from '../util';18import {expect, itSub, usingPlaygrounds} from '../util';191920describe('Integration Test: Composite nesting tests', () => {20describe('Integration Test: Composite nesting tests', () => {21 let alice: IKeyringPair;21 let alice: IKeyringPair;289 expect(await collectionFT.getBalance(targetToken.nestingAccount())).to.be.equal(7n);289 expect(await collectionFT.getBalance(targetToken.nestingAccount())).to.be.equal(7n);290 });290 });291292 // ---------- Re-Fungible ----------293294 itSub.ifWithPallets('ReFungible: allows an Owner to nest/unnest their token', [Pallets.ReFungible], async ({helper}) => {295 const collectionNFT = await helper.nft.mintCollection(alice, {permissions: {access: 'AllowList', mintMode: true, nesting: {tokenOwner: true}}});296 const collectionRFT = await helper.rft.mintCollection(alice);297 const targetToken = await collectionNFT.mintToken(alice, {Substrate: charlie.address});298299 await collectionNFT.addToAllowList(alice, {Substrate: charlie.address});300 await collectionNFT.addToAllowList(alice, targetToken.nestingAccount());301302 await collectionRFT.setPermissions(alice, {access: 'AllowList', mintMode: true});303 await collectionRFT.addToAllowList(alice, {Substrate: charlie.address});304 await collectionRFT.addToAllowList(alice, targetToken.nestingAccount());305306 // Create an immediately nested token307 const nestedToken = await collectionRFT.mintToken(charlie, 5n, targetToken.nestingAccount());308 expect(await nestedToken.getBalance(targetToken.nestingAccount())).to.be.equal(5n);309310 // Create a token to be nested and nest311 const newToken = await collectionRFT.mintToken(charlie, 5n);312 await newToken.transfer(charlie, targetToken.nestingAccount(), 2n);313 expect(await newToken.getBalance(targetToken.nestingAccount())).to.be.equal(2n);314 });315316 itSub.ifWithPallets('ReFungible: allows an Owner to nest/unnest their token (Restricted nesting)', [Pallets.ReFungible], async ({helper}) => {317 const collectionNFT = await helper.nft.mintCollection(alice);318 const collectionRFT = await helper.rft.mintCollection(alice);319 const targetToken = await collectionNFT.mintToken(alice, {Substrate: charlie.address});320321 await collectionNFT.setPermissions(alice, {access: 'AllowList', mintMode: true, nesting: {tokenOwner: true, restricted:[collectionRFT.collectionId]}});322 await collectionNFT.addToAllowList(alice, {Substrate: charlie.address});323 await collectionNFT.addToAllowList(alice, targetToken.nestingAccount());324325 await collectionRFT.setPermissions(alice, {access: 'AllowList', mintMode: true});326 await collectionRFT.addToAllowList(alice, {Substrate: charlie.address});327 await collectionRFT.addToAllowList(alice, targetToken.nestingAccount());328329 // Create an immediately nested token330 const nestedToken = await collectionRFT.mintToken(charlie, 5n, targetToken.nestingAccount());331 expect(await nestedToken.getBalance(targetToken.nestingAccount())).to.be.equal(5n);332333 // Create a token to be nested and nest334 const newToken = await collectionRFT.mintToken(charlie, 5n);335 await newToken.transfer(charlie, targetToken.nestingAccount(), 2n);336 expect(await newToken.getBalance(targetToken.nestingAccount())).to.be.equal(2n);337 });338});291});339292340describe('Negative Test: Nesting', () => {293describe('Negative Test: Nesting', () => {581 expect(await collectionFT.getBalance({Substrate: alice.address})).to.be.equal(5n);534 expect(await collectionFT.getBalance({Substrate: alice.address})).to.be.equal(5n);582 });535 });583584 // ---------- Re-Fungible ----------585586 itSub.ifWithPallets('ReFungible: disallows to nest token if nesting is disabled', [Pallets.ReFungible], async ({helper}) => {587 const collectionNFT = await helper.nft.mintCollection(alice);588 const collectionRFT = await helper.rft.mintCollection(alice);589 const targetToken = await collectionNFT.mintToken(alice);590591 // Try to create an immediately nested token592 await expect(collectionRFT.mintToken(alice, 5n, targetToken.nestingAccount()))593 .to.be.rejectedWith(/common\.UserIsNotAllowedToNest/);594595 // Try to create a token to be nested and nest596 const token = await collectionRFT.mintToken(alice, 5n);597 await expect(token.transfer(alice, targetToken.nestingAccount(), 2n))598 .to.be.rejectedWith(/common\.UserIsNotAllowedToNest/);599 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(5n);600 });601602 itSub.ifWithPallets('ReFungible: disallows a non-Owner to nest someone else\'s token', [Pallets.ReFungible], async ({helper}) => {603 const collectionNFT = await helper.nft.mintCollection(alice);604 const collectionRFT = await helper.rft.mintCollection(alice);605 const targetToken = await collectionNFT.mintToken(alice);606607 await collectionNFT.setPermissions(alice, {access: 'AllowList', mintMode: true, nesting: {tokenOwner: true}});608 await collectionNFT.addToAllowList(alice, {Substrate: bob.address});609 await collectionNFT.addToAllowList(alice, targetToken.nestingAccount());610611 // Try to create a token to be nested and nest612 const newToken = await collectionRFT.mintToken(alice);613 await expect(newToken.transfer(bob, targetToken.nestingAccount())).to.be.rejectedWith(/common\.TokenValueTooLow/);614615 expect(await targetToken.getChildren()).to.be.length(0);616 expect(await newToken.getBalance({Substrate: alice.address})).to.be.equal(1n);617618 // Nest some tokens as Alice into Bob's token619 await newToken.transfer(alice, targetToken.nestingAccount());620621 // Try to pull it out622 await expect(newToken.transferFrom(bob, targetToken.nestingAccount(), {Substrate: alice.address}, 1n))623 .to.be.rejectedWith(/common\.ApprovedValueTooLow/);624 expect(await newToken.getBalance(targetToken.nestingAccount())).to.be.equal(1n);625 });626627 itSub.ifWithPallets('ReFungible: disallows a non-Owner to nest someone else\'s token (Restricted nesting)', [Pallets.ReFungible], async ({helper}) => {628 const collectionNFT = await helper.nft.mintCollection(alice);629 const collectionRFT = await helper.rft.mintCollection(alice);630 const targetToken = await collectionNFT.mintToken(alice);631632 await collectionNFT.setPermissions(alice, {access: 'AllowList', mintMode: true, nesting: {tokenOwner: true, restricted: [collectionRFT.collectionId]}});633 await collectionNFT.addToAllowList(alice, {Substrate: bob.address});634 await collectionNFT.addToAllowList(alice, targetToken.nestingAccount());635636 // Try to create a token to be nested and nest637 const newToken = await collectionRFT.mintToken(alice);638 await expect(newToken.transfer(bob, targetToken.nestingAccount())).to.be.rejectedWith(/common\.TokenValueTooLow/);639640 expect(await targetToken.getChildren()).to.be.length(0);641 expect(await newToken.getBalance({Substrate: alice.address})).to.be.equal(1n);642643 // Nest some tokens as Alice into Bob's token644 await newToken.transfer(alice, targetToken.nestingAccount());645646 // Try to pull it out647 await expect(newToken.transferFrom(bob, targetToken.nestingAccount(), {Substrate: alice.address}, 1n))648 .to.be.rejectedWith(/common\.ApprovedValueTooLow/);649 expect(await newToken.getBalance(targetToken.nestingAccount())).to.be.equal(1n);650 });651652 itSub.ifWithPallets('ReFungible: disallows to nest token to an unlisted collection', [Pallets.ReFungible], async ({helper}) => {653 const collectionNFT = await helper.nft.mintCollection(alice, {permissions: {nesting: {tokenOwner: true, restricted: []}}});654 const collectionRFT = await helper.rft.mintCollection(alice);655 const targetToken = await collectionNFT.mintToken(alice);656657 // Try to create an immediately nested token658 await expect(collectionRFT.mintToken(alice, 5n, targetToken.nestingAccount()))659 .to.be.rejectedWith(/common\.SourceCollectionIsNotAllowedToNest/);660661 // Try to create a token to be nested and nest662 const token = await collectionRFT.mintToken(alice, 5n);663 await expect(token.transfer(alice, targetToken.nestingAccount(), 2n))664 .to.be.rejectedWith(/common\.SourceCollectionIsNotAllowedToNest/);665 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(5n);666 });667});536});668537tests/src/nesting/unnest.test.tsdiffbeforeafterboth64 expect(await targetToken.getChildren()).to.be.length(0);64 expect(await targetToken.getChildren()).to.be.length(0);65 });65 });6667 itSub.ifWithPallets('ReFungible: allows the owner to successfully unnest a token', [Pallets.ReFungible], async ({helper}) => {68 const collection = await helper.nft.mintCollection(alice, {permissions: {nesting: {tokenOwner: true}}});69 const targetToken = await collection.mintToken(alice);7071 const collectionRFT = await helper.rft.mintCollection(alice);7273 // Nest and unnest74 const token = await collectionRFT.mintToken(alice, 10n, targetToken.nestingAccount());75 await expect(token.transferFrom(alice, targetToken.nestingAccount(), {Substrate: alice.address}, 9n), 'while unnesting').to.be.fulfilled;76 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(9n);77 expect(await token.getBalance(targetToken.nestingAccount())).to.be.equal(1n);7879 // Nest and burn80 await token.transfer(alice, targetToken.nestingAccount(), 5n);81 await expect(token.burnFrom(alice, targetToken.nestingAccount(), 6n), 'while burning').to.be.fulfilled;82 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(4n);83 expect(await token.getBalance(targetToken.nestingAccount())).to.be.equal(0n);84 expect(await targetToken.getChildren()).to.be.length(0);85 });86});66});876788describe('Negative Test: Unnesting', () => {68describe('Negative Test: Unnesting', () => {tests/src/refungible.test.tsdiffbeforeafterboth88 expect((await token.getTop10Owners()).length).to.be.equal(10);88 expect((await token.getTop10Owners()).length).to.be.equal(10);89 });89 });9091 itSub('Transfer token pieces', async ({helper}) => {92 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});93 const token = await collection.mintToken(alice, 100n);9495 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(100n);96 expect(await token.transfer(alice, {Substrate: bob.address}, 60n)).to.be.true;9798 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(40n);99 expect(await token.getBalance({Substrate: bob.address})).to.be.equal(60n);100101 await expect(token.transfer(alice, {Substrate: bob.address}, 41n))102 .to.eventually.be.rejectedWith(/common\.TokenValueTooLow/);103 });10490105 itSub('Create multiple tokens', async ({helper}) => {91 itSub('Create multiple tokens', async ({helper}) => {106 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});92 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});120 expect(await collection.getTokenBalance(lastTokenId, {Substrate: alice.address})).to.be.equal(100n);106 expect(await collection.getTokenBalance(lastTokenId, {Substrate: alice.address})).to.be.equal(100n);121 });107 });122123 itSub('Burn some pieces', async ({helper}) => {124 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});125 const token = await collection.mintToken(alice, 100n);126 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;127 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(100n);128 expect(await token.burn(alice, 99n)).to.be.true;129 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;130 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(1n);131 });132133 itSub('Burn all pieces', async ({helper}) => {134 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});135 const token = await collection.mintToken(alice, 100n);136137 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;138 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(100n);139140 expect(await token.burn(alice, 100n)).to.be.true;141 expect(await collection.doesTokenExist(token.tokenId)).to.be.false;142 });143144 itSub('Burn some pieces for multiple users', async ({helper}) => {145 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});146 const token = await collection.mintToken(alice, 100n);147148 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;149150 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(100n);151 expect(await token.transfer(alice, {Substrate: bob.address}, 60n)).to.be.true;152153 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(40n);154 expect(await token.getBalance({Substrate: bob.address})).to.be.equal(60n);155156 expect(await token.burn(alice, 40n)).to.be.true;157158 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;159 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(0n);160161 expect(await token.burn(bob, 59n)).to.be.true;162163 expect(await token.getBalance({Substrate: bob.address})).to.be.equal(1n);164 expect(await collection.doesTokenExist(token.tokenId)).to.be.true;165166 expect(await token.burn(bob, 1n)).to.be.true;167168 expect(await collection.doesTokenExist(token.tokenId)).to.be.false;169 });170108171 itSub('Set allowance for token', async ({helper}) => {109 itSub('Set allowance for token', async ({helper}) => {172 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});110 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});183 expect(await token.getApprovedPieces({Substrate: alice.address}, {Substrate: bob.address})).to.be.equal(40n);121 expect(await token.getApprovedPieces({Substrate: alice.address}, {Substrate: bob.address})).to.be.equal(40n);184 });122 });185186 itSub('Repartition', async ({helper}) => {187 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});188 const token = await collection.mintToken(alice, 100n);189190 expect(await token.repartition(alice, 200n)).to.be.true;191 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(200n);192 expect(await token.getTotalPieces()).to.be.equal(200n);193194 expect(await token.transfer(alice, {Substrate: bob.address}, 110n)).to.be.true;195 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(90n);196 expect(await token.getBalance({Substrate: bob.address})).to.be.equal(110n);197198 await expect(token.repartition(alice, 80n))199 .to.eventually.be.rejectedWith(/refungible\.RepartitionWhileNotOwningAllPieces/);200201 expect(await token.transfer(alice, {Substrate: bob.address}, 90n)).to.be.true;202 expect(await token.getBalance({Substrate: alice.address})).to.be.equal(0n);203 expect(await token.getBalance({Substrate: bob.address})).to.be.equal(200n);204205 expect(await token.repartition(bob, 150n)).to.be.true;206 await expect(token.transfer(bob, {Substrate: alice.address}, 160n))207 .to.eventually.be.rejectedWith(/common\.TokenValueTooLow/);208 });209210 itSub('Repartition with increased amount', async ({helper}) => {211 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});212 const token = await collection.mintToken(alice, 100n);213 await token.repartition(alice, 200n);214 const chainEvents = helper.chainLog.slice(-1)[0].events;215 const event = chainEvents.find((event: any) => event.section === 'common' && event.method === 'ItemCreated');216 expect(event).to.deep.include({217 section: 'common',218 method: 'ItemCreated',219 index: [66, 2],220 data: [221 collection.collectionId,222 token.tokenId,223 {substrate: alice.address},224 100n,225 ],226 });227 });228229 itSub('Repartition with decreased amount', async ({helper}) => {230 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});231 const token = await collection.mintToken(alice, 100n);232 await token.repartition(alice, 50n);233 const chainEvents = helper.chainLog.slice(-1)[0].events;234 const event = chainEvents.find((event: any) => event.section === 'common' && event.method === 'ItemDestroyed');235 expect(event).to.deep.include({236 section: 'common',237 method: 'ItemDestroyed',238 index: [66, 3],239 data: [240 collection.collectionId,241 token.tokenId,242 {substrate: alice.address},243 50n,244 ],245 });246 });247123248 itSub('Create new collection with properties', async ({helper}) => {124 itSub('Create new collection with properties', async ({helper}) => {249 const properties = [{key: 'key1', value: 'val1'}];125 const properties = [{key: 'key1', value: 'val1'}];255 });131 });256});132});257258describe('Refungible negative tests', () => {259 let donor: IKeyringPair;260 let alice: IKeyringPair;261 let bob: IKeyringPair;262 let charlie: IKeyringPair;263264 before(async function() {265 await usingPlaygrounds(async (helper, privateKey) => {266 requirePalletsOrSkip(this, helper, [Pallets.ReFungible]);267268 donor = await privateKey({filename: __filename});269 [alice, bob, charlie] = await helper.arrange.createAccounts([100n, 100n, 100n], donor);270 });271 });272273 itSub('Cannot transfer incorrect amount of token pieces', async ({helper}) => {274 const collection = await helper.rft.mintCollection(alice, {name: 'test', description: 'test', tokenPrefix: 'test'});275 const tokenAlice = await collection.mintToken(alice, 10n, {Substrate: alice.address});276 const tokenBob = await collection.mintToken(alice, 10n, {Substrate: bob.address});277278 // 1. Alice cannot transfer Bob's token:279 await expect(tokenBob.transfer(alice, {Substrate: charlie.address}, 0n)).to.be.rejectedWith('common.TokenValueTooLow');280 await expect(tokenBob.transfer(alice, {Substrate: charlie.address}, 1n)).to.be.rejectedWith('common.TokenValueTooLow');281 await expect(tokenBob.transfer(alice, {Substrate: charlie.address}, 10n)).to.be.rejectedWith('common.TokenValueTooLow');282 await expect(tokenBob.transfer(alice, {Substrate: charlie.address}, 100n)).to.be.rejectedWith('common.TokenValueTooLow');283284 // 2. Alice cannot transfer non-existing token:285 await expect(collection.transferToken(alice, 100, {Substrate: charlie.address}, 0n)).to.be.rejectedWith('common.TokenValueTooLow');286 await expect(collection.transferToken(alice, 100, {Substrate: charlie.address}, 1n)).to.be.rejectedWith('common.TokenValueTooLow');287288 // 3. Zero transfer allowed (EIP-20):289 await tokenAlice.transfer(alice, {Substrate: charlie.address}, 0n);290291 expect(await tokenAlice.getTop10Owners()).to.deep.eq([{Substrate: alice.address}]);292 expect(await tokenBob.getTop10Owners()).to.deep.eq([{Substrate: bob.address}]);293 expect(await tokenAlice.getBalance({Substrate: alice.address})).to.eq(10n);294 expect(await tokenBob.getBalance({Substrate: bob.address})).to.eq(10n);295 expect(await tokenBob.getBalance({Substrate: charlie.address})).to.eq(0n);296 });297});298133tests/src/sub/refungible/burn.test.tsdiffbeforeafterbothno changes
tests/src/sub/refungible/nesting.test.tsdiffbeforeafterbothno changes
tests/src/sub/refungible/repartition.test.tsdiffbeforeafterbothno changes
tests/src/sub/refungible/transfer.test.tsdiffbeforeafterbothno changes