Skip to content

Commit

Permalink
test: Add fuzz test to timestamp in claimReferralFees
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathandiep committed Apr 9, 2024
1 parent 1c52379 commit 14e515b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/Quest.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,8 @@ contract TestQuest is Test, TestUtils, Errors, Events {
CLAIM REFERRAL FEES
//////////////////////////////////////////////////////////////*/

function testFuzz_claimReferralFees() public {
function test_fuzz_claimReferralFees(uint96 timestamp) public {
vm.assume(timestamp > END_TIME);
QuestFactoryMock(questFactoryMock).setMintFee(CLAIM_FEE);
QuestFactoryMock(questFactoryMock).setNumberMinted(TOTAL_PARTICIPANTS);

Expand Down Expand Up @@ -360,7 +361,7 @@ contract TestQuest is Test, TestUtils, Errors, Events {
"referral claims for all referrers should equal the reward amount (single claim)"
);

vm.warp(END_TIME);
vm.warp(timestamp);
vm.prank(referrer);
quest.claimReferralFees(referrer);

Expand Down

0 comments on commit 14e515b

Please sign in to comment.