diff --git a/contracts/mocks/SafeERC20Helper.sol b/contracts/mocks/SafeERC20Helper.sol index 3392f7301..0dd602ffe 100644 --- a/contracts/mocks/SafeERC20Helper.sol +++ b/contracts/mocks/SafeERC20Helper.sol @@ -36,10 +36,6 @@ contract ERC20FailingMock is IERC20 { function allowance(address, address) public view returns (uint256) { return 0; } - - function setAllowance(uint256 value) public { - _allowance = value; - } } contract ERC20SucceedingMock is IERC20 { @@ -153,17 +149,4 @@ contract SafeERC20Helper { function doSucceedingApprove() public { _succeeding.safeApprove(address(0), 0); } - - function doFailingApproveByValue() public { - _succeeding.setAllowance(10); - _succeeding.safeApprove(address(0), 10); - } - - function doSucceedingIncreaseAllowance() public { - _succeeding.safeIncreaseAllowance(address(0), 0); - } - - function doSucceedingDecreaseAllowance() public { - _succeeding.safeDecreaseAllowance(address(0), 0); - } } diff --git a/contracts/token/ERC20/IERC20.sol b/contracts/token/ERC20/IERC20.sol index f2118d6ae..ac2d85331 100644 --- a/contracts/token/ERC20/IERC20.sol +++ b/contracts/token/ERC20/IERC20.sol @@ -17,15 +17,6 @@ interface IERC20 { function transferFrom(address from, address to, uint256 value) external returns (bool); - function increaseAllowance(address spender, uint256 addedValue) - external returns (bool); - - function decreaseAllowance(address spender, uint256 subtractedValue) - external returns (bool); - - function setAllowance(uint256 value) - external returns (bool); - event Transfer( address indexed from, address indexed to, diff --git a/test/token/ERC20/SafeERC20.test.js b/test/token/ERC20/SafeERC20.test.js index 687e6ee87..b3149658f 100644 --- a/test/token/ERC20/SafeERC20.test.js +++ b/test/token/ERC20/SafeERC20.test.js @@ -98,16 +98,4 @@ contract('SafeERC20', function () { }); }); }); - - it('should throw while approving with non-zero existing allowance', async function () { - await shouldFail.reverting(this.helper.doFailingApproveByValue()); - }); - - it('should not throw on succeeding increaseAllowance', async function () { - await this.helper.doSucceedingIncreaseAllowance(); - }); - - it('should not throw on succeeding decreaseAllowance', async function () { - await this.helper.doSucceedingDecreaseAllowance(); - }); });