* Improve ERC20/721 Pausable docs * Add ERC20Pausable mint and burn tests * Add ERC721Pausable mint and burn tests * Add _beforeTransfer hook in ERC777 to mint and burn
32 lines
678 B
Solidity
32 lines
678 B
Solidity
pragma solidity ^0.6.0;
|
|
|
|
import "../token/ERC20/ERC20Pausable.sol";
|
|
|
|
// mock class using ERC20Pausable
|
|
contract ERC20PausableMock is ERC20Pausable {
|
|
constructor (
|
|
string memory name,
|
|
string memory symbol,
|
|
address initialAccount,
|
|
uint256 initialBalance
|
|
) public ERC20(name, symbol) {
|
|
_mint(initialAccount, initialBalance);
|
|
}
|
|
|
|
function pause() external {
|
|
_pause();
|
|
}
|
|
|
|
function unpause() external {
|
|
_unpause();
|
|
}
|
|
|
|
function mint(address to, uint256 amount) public {
|
|
_mint(to, amount);
|
|
}
|
|
|
|
function burn(address from, uint256 amount) public {
|
|
_burn(from, amount);
|
|
}
|
|
}
|