Skip to content

Commit

Permalink
Add reserve test
Browse files Browse the repository at this point in the history
  • Loading branch information
neokry committed Dec 13, 2023
1 parent 2acc3be commit 7c7f5e8
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test/Gov.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -1161,6 +1161,14 @@ contract GovTest is NounsBuilderTest, GovernorTypesV1 {
mock1155.mintBatch(address(governor), _tokenIds, _amounts);
}

function testRevert_GovernorOnlyDAOWithReserveCanAddDelay() public {
deployMock();

vm.prank(founder);
vm.expectRevert(abi.encodeWithSignature("CANNOT_DELAY_GOVERNANCE()"));
governor.updateDelayedGovernanceExpirationTimestamp(1 days);
}

function testRevert_GovernorOnlyTokenOwnerCanSetDelay() public {
deployMock();

Expand All @@ -1180,6 +1188,9 @@ contract GovTest is NounsBuilderTest, GovernorTypesV1 {
function testRevert_GovernorCannotSetDelayAfterTokensAreMinted() public {
deployMock();

vm.prank(founder);
token.setReservedUntilTokenId(4);

vm.prank(founder);
auction.unpause();

Expand Down

0 comments on commit 7c7f5e8

Please sign in to comment.