git.delta.rocks / unique-network / refs/commits / 2d642d0d62f4

difftreelog

tests: fix bigint equality check

Yaroslav Bolyukin2021-02-12parent: #bab6ffe.patch.diff
in: master

1 file changed

modifiedtests/src/overflow.test.tsdiffbeforeafterboth
55 await transferFromExpectSuccess(fungibleCollectionId, 0, bob, alice, charlie, U128_MAX, 'Fungible');55 await transferFromExpectSuccess(fungibleCollectionId, 0, bob, alice, charlie, U128_MAX, 'Fungible');
5656
57 expect(await getFungibleBalance(fungibleCollectionId, charlie.address)).to.equal(U128_MAX);57 expect(await getFungibleBalance(fungibleCollectionId, charlie.address)).to.equal(U128_MAX);
58 expect(await getAllowance(fungibleCollectionId, 0, alice.address, bob.address)).to.equal(0n);58 expect((await getAllowance(fungibleCollectionId, 0, alice.address, bob.address)).toString()).to.equal('0');
5959
60 await createFungibleItemExpectSuccess(alice, fungibleCollectionId, { Value: U128_MAX });60 await createFungibleItemExpectSuccess(alice, fungibleCollectionId, { Value: U128_MAX });
61 await approveExpectSuccess(fungibleCollectionId, 0, alice, bob, 1n);61 await approveExpectSuccess(fungibleCollectionId, 0, alice, bob, 1n);
62 await transferFromExpectFail(fungibleCollectionId, 0, bob, alice, charlie, 1);62 await transferFromExpectFail(fungibleCollectionId, 0, bob, alice, charlie, 1);
6363
64 expect(await getFungibleBalance(fungibleCollectionId, charlie.address)).to.equal(U128_MAX);64 expect(await getFungibleBalance(fungibleCollectionId, charlie.address)).to.equal(U128_MAX);
65 expect(await getAllowance(fungibleCollectionId, 0, alice.address, bob.address)).to.equal(0n);65 expect((await getAllowance(fungibleCollectionId, 0, alice.address, bob.address)).toString()).to.equal('1');
66 });66 });
67});67});
6868