-
Notifications
You must be signed in to change notification settings - Fork 14
Fix balance checks in integration tests #165
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
[ | ||
expectedProxyBalanceChange, // Proxy | ||
-taskPrice * completedTasks, // Requester | ||
0, // Requester |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
workerStakePerTask | ||
); | ||
expect(finalizeTx).to.changeTokenBalances( | ||
await expect(finalizeTx).to.changeTokenBalances( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
I suggest to use a clearer name for the PR: |
.then((tx) => tx.wait()); | ||
return await extractRegistryEntryAddress(workerpoolReceipt, workerpoolRegistry.address); | ||
} | ||
async getInitialFrozens(accounts: SignerWithAddress[]) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
async getInitialFrozens(accounts: SignerWithAddress[]) { | |
async getInitialFrozens(accounts: SignerWithAddress[]) { |
test/utils/IexecWrapper.ts
Outdated
await IexecInterfaceNative__factory.connect( | ||
this.proxyAddress, | ||
ethers.provider, | ||
).frozenOf(this.proxyAddress) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Create one iexecPoco instance inside the function and re-use it.
test/utils/IexecWrapper.ts
Outdated
await IexecInterfaceNative__factory.connect( | ||
this.proxyAddress, | ||
ethers.provider, | ||
).frozenOf(accountsInitialFrozens[i].address) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same thing, create one instance outside of the for loop.
No description provided.