Skip to content

Commit

Permalink
test: testRevertConstructorZeroAddressParams;
Browse files Browse the repository at this point in the history
  • Loading branch information
yan-man committed Sep 4, 2024
1 parent 038e3be commit c574b35
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/test/TestGsmConverter.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,18 @@ contract TestGsmConverter is TestGhoBase {
'Unexpected redeemed asset address'
);
}

function testRevertConstructorZeroAddressParams() public {
vm.expectRevert('ZERO_ADDRESS_NOT_VALID');
new GsmConverter(address(0), address(REDEMPTION), address(BUIDL_TOKEN), address(USDC_TOKEN));

vm.expectRevert('ZERO_ADDRESS_NOT_VALID');
new GsmConverter(address(GHO_GSM), address(0), address(BUIDL_TOKEN), address(USDC_TOKEN));

vm.expectRevert('ZERO_ADDRESS_NOT_VALID');
new GsmConverter(address(GHO_GSM), address(REDEMPTION), address(0), address(USDC_TOKEN));

vm.expectRevert('ZERO_ADDRESS_NOT_VALID');
new GsmConverter(address(GHO_GSM), address(REDEMPTION), address(BUIDL_TOKEN), address(0));
}
}

0 comments on commit c574b35

Please sign in to comment.