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

chore: add dummy test to trigger storage collision workflow failure #22

Open
wants to merge 2 commits into
base: development
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
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
1 change: 1 addition & 0 deletions .github/workflows/core-contracts-storage-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ jobs:
check_storage_layout:
needs: provide_contracts
runs-on: ubuntu-latest
if: ${{ needs.provide_contracts.outputs.matrix != '[]' && needs.provide_contracts.outputs.matrix != '' }}

strategy:
matrix:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/diamond-storage-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ jobs:
check_storage_layout:
needs: provide_contracts
runs-on: ubuntu-latest
if: ${{ needs.provide_contracts.outputs.matrix != '[]' && needs.provide_contracts.outputs.matrix != '' }}

strategy:
matrix:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -471,4 +471,30 @@ contract UbiquityPoolFacetFuzzTest is DiamondTestSetup {
dollarTokenBalanceBeforeRedeem - tokenAmountToRedeem
);
}

function testMintDollar_FuzzCorrectDollarAmountRedeemed2(
uint256 tokenAmountToRedeem
) public {
vm.assume(tokenAmountToRedeem < 50_000e18);
vm.startPrank(admin);
curveDollarPlainPool.updateMockParams(0.99e18);
dollarToken.mint(address(user), tokenAmountToRedeem); // make sure user has enough Dollars
collateralToken.mint(address(ubiquityPoolFacet), tokenAmountToRedeem); // make sure pool has enough collateral
uint256 dollarTokenBalanceBeforeRedeem = dollarToken.balanceOf(user);
vm.stopPrank();
vm.prank(user);
ubiquityPoolFacet.redeemDollar(
0, // collateral index
tokenAmountToRedeem, // Dollar amount
0, // min Governance out
0 // min collateral out
);
vm.roll(3); // redemption delay set to 2 blocks
ubiquityPoolFacet.collectRedemption(0);
// balances after
assertEq(
dollarToken.balanceOf(user),
dollarTokenBalanceBeforeRedeem - tokenAmountToRedeem
);
}
}
Loading