mirror of
https://github.com/status-im/ens-usernames.git
synced 2025-02-23 15:48:11 +00:00
* trim trailing spaces * update to embark 4.0.2 * bump to solc 0.5.4 * use .selector * use solidity function selector * update to embark 6.0.0 * use mocks instead of "instanceOf" tool+tests fix * update to solidity 0.5.11 * update to solidity 0.5.11 * add spdx license identifiers * update ENS contracts * natspec fix return values
34 lines
795 B
Solidity
34 lines
795 B
Solidity
// SPDX-License-Identifier: CC0-1.0
|
|
|
|
pragma solidity 0.5.11;
|
|
|
|
import "./StandardToken.sol";
|
|
import "./ApproveAndCallFallBack.sol";
|
|
|
|
/**
|
|
* @notice ERC20Token for test scripts, can be minted by anyone.
|
|
*/
|
|
contract TestToken is StandardToken {
|
|
|
|
constructor() public { }
|
|
|
|
/**
|
|
* @notice any caller can mint any `_amount`
|
|
* @param _amount how much to be minted
|
|
*/
|
|
function mint(uint256 _amount) public {
|
|
mint(msg.sender, _amount);
|
|
}
|
|
|
|
|
|
function approveAndCall(address _spender, uint256 _value, bytes calldata _extraData)
|
|
external
|
|
returns (bool success)
|
|
{
|
|
approve(msg.sender, _spender, _value);
|
|
ApproveAndCallFallBack(_spender).receiveApproval(msg.sender, _value, address(this), _extraData);
|
|
return true;
|
|
}
|
|
|
|
}
|