Skip to content

Commit

Permalink
update contract
Browse files Browse the repository at this point in the history
  • Loading branch information
rouzwelt committed May 24, 2024
1 parent 66dfe21 commit b215bb6
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 25 deletions.
8 changes: 0 additions & 8 deletions test-contracts/erc165/ERC165Supported.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,6 @@ import {IERC165} from "../../lib/forge-std/src/interfaces/IERC165.sol";

/// A contract that implements erc165
contract ERC165Supported is IERC165 {
function externalFn() external pure returns (bool) {
return internalFn(true);
}

function internalFn(bool val) internal pure returns (bool) {
return val;
}

function supportsInterface(bytes4 interfaceID) external pure returns (bool) {
return (interfaceID == type(IERC165).interfaceId);
}
Expand Down
8 changes: 0 additions & 8 deletions test-contracts/erc165/InvalidERC165.sol
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,6 @@ pragma solidity =0.8.25;

/// A contract that doesnt implement erc165, but has supportsInterface method
contract InvalidERC165 {
function externalFn() external pure returns (bool) {
return internalFn(true);
}

function internalFn(bool val) internal pure returns (bool) {
return val;
}

function supportsInterface(bytes4 interfaceID) external pure returns (bool) {
(interfaceID);
return true;
Expand Down
10 changes: 1 addition & 9 deletions test-contracts/erc165/NonERC165.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,4 @@
pragma solidity =0.8.25;

/// A contract that doesnt implement erc165
contract NonERC165 {
function externalFn() external pure returns (bool) {
return internalFn();
}

function internalFn() internal pure returns (bool) {
return true;
}
}
contract NonERC165 {}

0 comments on commit b215bb6

Please sign in to comment.