-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: rename GelatoRelayerContext with GELATO_RELAY constant and …
…no constructor (#3)
- Loading branch information
Showing
10 changed files
with
504 additions
and
488 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
# yarn test | ||
yarn test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
node_modules/ | ||
contracts/functions | ||
contracts/vendor | ||
contracts/interfaces | ||
contracts/__mocks__ | ||
contracts/vendor | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.1; | ||
|
||
// import { | ||
// GelatoRelayerContext | ||
// } from "@gelatonetwork/relayer-context/contracts/GelatoRelayerContext.sol"; | ||
import {GelatoRelayerContext} from "../GelatoRelayerContext.sol"; | ||
|
||
contract MockGelatoRelayerContext is GelatoRelayerContext { | ||
event LogMsgData(bytes msgData); | ||
event LogFnArgs(bytes fnArgs); | ||
event LogContext(address feeCollector, address feeToken, uint256 fee); | ||
|
||
function emitContext() external { | ||
emit LogMsgData(msg.data); | ||
emit LogFnArgs(_msgData()); | ||
emit LogContext(_getFeeCollector(), _getFeeToken(), _getFee()); | ||
} | ||
|
||
function testTransferRelayFee() external { | ||
_transferRelayFee(); | ||
} | ||
|
||
function testTransferRelayFeeCapped(uint256 _maxFee) external { | ||
_transferRelayFeeCapped(_maxFee); | ||
} | ||
|
||
// solhint-disable-next-line no-empty-blocks | ||
function testOnlyRelayer() external onlyRelayer {} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.1; | ||
|
||
address constant GELATO_RELAY = 0xaBcC9b596420A9E9172FD5938620E265a0f9Df92; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.