From 1f0d81d5f19f87ee5664e4cbc2d4fbc8cf531476 Mon Sep 17 00:00:00 2001 From: Daniel Shiposha Date: Wed, 17 Aug 2022 12:52:37 +0000 Subject: [PATCH] fix(test): use getFreeBalance instead of long line --- --- a/tests/src/deprecated-helpers/helpers.ts +++ b/tests/src/deprecated-helpers/helpers.ts @@ -1235,12 +1235,12 @@ scheduleMethod, ); - const recipientBalanceBefore = (await api.query.system.account(recipient.address)).data.free.toBigInt(); + const recipientBalanceBefore = await getFreeBalance(recipient); // sleep for n + 1 blocks await waitNewBlocks(blocksBeforeExecution + 1); - const recipientBalanceAfter = (await api.query.system.account(recipient.address)).data.free.toBigInt(); + const recipientBalanceAfter = await getFreeBalance(recipient); expect(await getTokenOwner(api, collectionId, tokenId)).to.be.deep.equal(normalizeAccountId(recipient.address)); expect(recipientBalanceAfter).to.be.equal(recipientBalanceBefore); -- gitstuff