Move Forwarder test to integrations; update to use new framework
This commit is contained in:
@@ -41,6 +41,18 @@ export class LocalBalanceStore extends BalanceStore {
|
||||
this._balances.eth[senderAddress] = this._balances.eth[senderAddress].minus(amount);
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts some amount of the ETH balance of an address to WETH balance to simulate wrapping ETH.
|
||||
* @param senderAddress Address whose ETH to wrap.
|
||||
* @param amount Amount to wrap.
|
||||
*/
|
||||
public wrapEth(senderAddress: string, wethAddress: string, amount: Numberish): void {
|
||||
this._balances.eth[senderAddress] = this._balances.eth[senderAddress].minus(amount);
|
||||
_.update(this._balances.erc20, [senderAddress, wethAddress], balance =>
|
||||
(balance || constants.ZERO_AMOUNT).plus(amount),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sends ETH from `fromAddress` to `toAddress`.
|
||||
* @param fromAddress Sender of ETH.
|
||||
|
Reference in New Issue
Block a user