From 48eb4a2324952d82cd30e13ca35ce17689ae003c Mon Sep 17 00:00:00 2001 From: alexcos20 Date: Tue, 21 Nov 2023 20:27:56 +0200 Subject: [PATCH] add withMint=True and delete sell test --- test/integration/users.test.ts | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/test/integration/users.test.ts b/test/integration/users.test.ts index afd791ba..fab1fd1b 100644 --- a/test/integration/users.test.ts +++ b/test/integration/users.test.ts @@ -123,7 +123,7 @@ describe('User tests', async () => { fixedRate: price, marketFee: publishMarketSwapFee, allowedConsumer: ZERO_ADDRESS, - withMint: false + withMint: true } const result = await Factory.createNftWithDatatokenWithFixedRate( @@ -196,27 +196,6 @@ describe('User tests', async () => { assert(user.totalSales === '0', 'incorrect value for: totalSales') assert(user.__typename === 'User', 'incorrect value for: __typename') }) - it('User1 sells a datatoken', async () => { - const initialUser = await userQuery(user1) - await datatoken.approve(datatokenAddress, fixedRateAddress, dtAmount, user1) - const tx = (await fixedRate.sellDatatokens(user1, exchangeId, '10', '9')) - .events?.Swapped - - assert(tx != null) - const user = await userQuery(user1) - - assert(user.id === user1, 'incorrect value for: id') - assert(user.tokenBalancesOwned.length === 0, 'incorrect tokenBalancesOwned') - assert(user.orders.length === 0, 'incorrect value for: orders') - assert( - user.freSwaps.length === initialUser.freSwaps.length, - 'incorrect value for: freSwaps' - ) - assert(user.totalOrders === '0', 'incorrect value for: totalOrders') - assert(user.totalSales === '0', 'incorrect value for: totalSales') - assert(user.__typename === 'User', 'incorrect value for: __typename') - }) - it('Check user fields after publishing & ordering a datatoken', async () => { // Start with publishing a new datatoken const nftParams: NftCreateData = {