Skip to content

Commit

Permalink
test: implement random withdrawal generator (#349)
Browse files Browse the repository at this point in the history
see PR for changes/notes
  • Loading branch information
wadealexc authored and ypatil12 committed Dec 4, 2023
1 parent 950eee3 commit fe80744
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions src/test/integration/IntegrationBase.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -355,13 +355,9 @@ abstract contract IntegrationBase is IntegrationDeployer {
// Use timewarp to get previous token balances
uint[] memory prevTokenBalances = _getPrevTokenBalances(staker, tokens);

for (uint i = 0; i < strategies.length; i++) {
// Ignore BeaconChainETH strategy since it doesn't keep track of global strategy shares
if (strategies[i] == BEACONCHAIN_ETH_STRAT) {
continue;
}
uint256 prevShare = prevShares[i];
uint256 curShare = curShares[i];
for (uint i = 0; i < tokens.length; i++) {
uint prevBalance = prevTokenBalances[i];
uint curBalance = curTokenBalances[i];

assertEq(prevBalance - removedTokens[i], curBalance, err);
}
Expand Down

0 comments on commit fe80744

Please sign in to comment.