Contract Wrappers - Ether token block range
Start after migrations to avoid any unexpected logs
This commit is contained in:
parent
81b4f4928d
commit
0b6ea1d046
@ -336,15 +336,19 @@ describe('EtherTokenWrapper', () => {
|
|||||||
describe('#getLogsAsync', () => {
|
describe('#getLogsAsync', () => {
|
||||||
let etherTokenAddress: string;
|
let etherTokenAddress: string;
|
||||||
let erc20ProxyAddress: string;
|
let erc20ProxyAddress: string;
|
||||||
const blockRange: BlockRange = {
|
let blockRange: BlockRange;
|
||||||
fromBlock: 0,
|
|
||||||
toBlock: BlockParamLiteral.Latest,
|
|
||||||
};
|
|
||||||
let txHash: string;
|
let txHash: string;
|
||||||
before(() => {
|
before(async () => {
|
||||||
addressWithETH = userAddresses[0];
|
addressWithETH = userAddresses[0];
|
||||||
etherTokenAddress = tokenUtils.getWethTokenAddress();
|
etherTokenAddress = tokenUtils.getWethTokenAddress();
|
||||||
erc20ProxyAddress = contractWrappers.erc20Proxy.getContractAddress();
|
erc20ProxyAddress = contractWrappers.erc20Proxy.getContractAddress();
|
||||||
|
// Start the block range after all migrations to avoid unexpected logs
|
||||||
|
const currentBlock = await web3Wrapper.getBlockNumberAsync();
|
||||||
|
const fromBlock = currentBlock + 1;
|
||||||
|
blockRange = {
|
||||||
|
fromBlock,
|
||||||
|
toBlock: BlockParamLiteral.Latest,
|
||||||
|
};
|
||||||
});
|
});
|
||||||
it('should get logs with decoded args emitted by Approval', async () => {
|
it('should get logs with decoded args emitted by Approval', async () => {
|
||||||
txHash = await contractWrappers.erc20Token.setUnlimitedProxyAllowanceAsync(
|
txHash = await contractWrappers.erc20Token.setUnlimitedProxyAllowanceAsync(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user