Skip to content

Commit

Permalink
odd fix for fuzz test
Browse files Browse the repository at this point in the history
  • Loading branch information
apenzk committed Feb 24, 2025
1 parent e315a31 commit 22a790c
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ contract MOVETokenDevTest is Test {
// repeat with new test if messenger is multisig or 0
vm.assume(messenger != multisig);
vm.assume(messenger != address(0));
console.log("............................");
console.log("............................"); // TODO : if the console logs are removed, the test fails, why?
console.log("messenger", messenger);
console.log("multisig", multisig);
console.log("............................");
Expand All @@ -146,10 +146,13 @@ contract MOVETokenDevTest is Test {
// Expect the call to revert with AccessControlUnauthorizedAccount error
// - messenger: the account trying to grant the role
// - DEFAULT_ADMIN_ROLE (0x00): the role needed to grant any role
console.log("... messenger", messenger);
console.logBytes32(DEFAULT_ADMIN_ROLE);
vm.expectRevert(
abi.encodeWithSelector(IAccessControl.AccessControlUnauthorizedAccount.selector, messenger, DEFAULT_ADMIN_ROLE)
);


// Attempt to grant MINTER_ROLE to receiver address
// This should fail since messenger doesn't have DEFAULT_ADMIN_ROLE
token.grantRole(MINTER_ROLE, receiver);
Expand Down

0 comments on commit 22a790c

Please sign in to comment.