Skip to content
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

fix: just check that the balance after is greater than before #4587

Merged
merged 2 commits into from
Feb 29, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions bouncer/tests/broker_fee_collection_test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ async function testBrokerFees(asset: Asset, seed?: string): Promise<void> {
console.log('depositAmount:', depositAmount);
assert(
depositAmount >= minExpectedDepositAmount && depositAmount <= testSwapAmount,
`Unexpected ${asset} deposit amount ${depositAmount}, expected >=${minExpectedDepositAmount}, did gas fees change? detectedGasFee: ${
testSwapAmount - depositAmount
`Unexpected ${asset} deposit amount ${depositAmount}, expected >=${minExpectedDepositAmount}, did gas fees change? detectedGasFee: ${testSwapAmount - depositAmount
}`,
);

Expand Down Expand Up @@ -190,8 +189,8 @@ async function testBrokerFees(asset: Asset, seed?: string): Promise<void> {
console.log('Ethereum chain tracking state:', chainState);
}
assert(
balanceAfterWithdrawalBigInt <= balanceBeforeWithdrawalBigInt + earnedBrokerFeesAfter,
`Unexpected ${asset} balance after withdrawal, amount ${balanceAfterWithdrawalBigInt}, did gas fees change?`,
balanceAfterWithdrawalBigInt > balanceBeforeWithdrawalBigInt,
`Balance after withdrawal is less than balance before withdrawal.`,
);
}

Expand Down
Loading