Skip to content

Commit

Permalink
fix: typo
Browse files Browse the repository at this point in the history
  • Loading branch information
kasperpawlowski committed Mar 21, 2024
1 parent db5282f commit afbac59
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/unit/esynth/ESynthGeneral.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,13 @@ contract ESynthGeneralTest is ESynthTest {
assertEq(minted, 0);
}

function testFuzz_burnFromUser(uint128 amount) public {
function testFuzz_burnFromOwner(uint128 amount) public {
amount = uint128(bound(amount, 1, MAX_ALLOWED));
esynth.setCapacity(user1, MAX_ALLOWED);
vm.prank(user1);
esynth.mint(user1, amount);

// the owner of the synth can always burn from synth but cannot from other accounts without allowance
vm.expectRevert(abi.encodeWithSelector(ERC20InsufficientAllowance.selector, address(this), 0, amount));
esynth.burn(user1, amount);

Expand Down

0 comments on commit afbac59

Please sign in to comment.