The home for Hyperlane core contracts, sdk packages, and other infrastructure
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
hyperlane-monorepo/solidity/contracts/test/avs/TestPaymentCoordinator.sol

21 lines
729 B

// SPDX-License-Identifier: MIT OR Apache-2.0
pragma solidity >=0.8.0;
import {IPaymentCoordinator} from "../../interfaces/avs/vendored/IPaymentCoordinator.sol";
import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol";
import {SafeERC20} from "@openzeppelin/contracts/token/ERC20/utils/SafeERC20.sol";
contract TestPaymentCoordinator is IPaymentCoordinator {
using SafeERC20 for IERC20;
function payForRange(RangePayment[] calldata rangePayments) external {
for (uint256 i = 0; i < rangePayments.length; i++) {
rangePayments[i].token.safeTransferFrom(
msg.sender,
address(this),
rangePayments[i].amount
);
}
}
}