Skip to content

Commit

Permalink
test: improve weights in assumes
Browse files Browse the repository at this point in the history
  • Loading branch information
0xAustrian committed May 16, 2024
1 parent 37fdc76 commit 222e40f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/unit/BPool.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -1040,9 +1040,9 @@ contract BPool_Unit_JoinswapPoolAmountOut is BasePoolTest {

function _assumeHappyPath(JoinswapPoolAmountOut_FuzzScenario memory _fuzz) internal view {
// safe bound assumptions
_fuzz.tokenInDenorm = bound(_fuzz.tokenInDenorm, MIN_WEIGHT, MAX_WEIGHT);
_fuzz.tokenInDenorm = bound(_fuzz.tokenInDenorm, MIN_WEIGHT, MAX_WEIGHT / 2);
_fuzz.swapFee = bound(_fuzz.swapFee, MIN_FEE, MAX_FEE);
_fuzz.totalWeight = bound(_fuzz.totalWeight, MIN_WEIGHT * MAX_BOUND_TOKENS, MAX_WEIGHT * MAX_BOUND_TOKENS);
_fuzz.totalWeight = bound(_fuzz.totalWeight, MIN_WEIGHT * MAX_BOUND_TOKENS, MAX_TOTAL_WEIGHT);

// min
vm.assume(_fuzz.totalSupply >= INIT_POOL_SUPPLY);
Expand Down

0 comments on commit 222e40f

Please sign in to comment.