Added makeInterfaceId tests. (#1530)
This commit is contained in:
15
contracts/mocks/OwnableInterfaceId.sol
Normal file
15
contracts/mocks/OwnableInterfaceId.sol
Normal file
@ -0,0 +1,15 @@
|
||||
pragma solidity ^0.4.24;
|
||||
|
||||
import "../ownership/Ownable.sol";
|
||||
|
||||
/**
|
||||
* @title Ownable interface id calculator.
|
||||
* @dev See the EIP165 specification for more information:
|
||||
* https://github.com/ethereum/EIPs/blob/master/EIPS/eip-165.md#specification
|
||||
*/
|
||||
contract OwnableInterfaceId {
|
||||
function getInterfaceId() public pure returns (bytes4) {
|
||||
Ownable i;
|
||||
return i.owner.selector ^ i.isOwner.selector ^ i.renounceOwnership.selector ^ i.transferOwnership.selector;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user