Finalize test migration: remove legacy dependencies and test helpers (#4797)
This commit is contained in:
@ -3,7 +3,7 @@ const { expect } = require('chai');
|
||||
const { loadFixture } = require('@nomicfoundation/hardhat-network-helpers');
|
||||
|
||||
const { min } = require('../helpers/math');
|
||||
const { bigint: time } = require('../helpers/time');
|
||||
const time = require('../helpers/time');
|
||||
|
||||
const { shouldBehaveLikeVesting } = require('./VestingWallet.behavior');
|
||||
|
||||
@ -39,7 +39,7 @@ async function fixture() {
|
||||
},
|
||||
token: {
|
||||
checkRelease: async (tx, amount) => {
|
||||
await expect(tx).to.emit(token, 'Transfer').withArgs(mock.target, beneficiary.address, amount);
|
||||
await expect(tx).to.emit(token, 'Transfer').withArgs(mock, beneficiary, amount);
|
||||
await expect(tx).to.changeTokenBalances(token, [mock, beneficiary], [-amount, amount]);
|
||||
},
|
||||
setupFailure: async () => {
|
||||
@ -50,8 +50,8 @@ async function fixture() {
|
||||
};
|
||||
},
|
||||
releasedEvent: 'ERC20Released',
|
||||
argsVerify: [token.target],
|
||||
args: [ethers.Typed.address(token.target)],
|
||||
argsVerify: [token],
|
||||
args: [ethers.Typed.address(token)],
|
||||
},
|
||||
};
|
||||
|
||||
@ -76,7 +76,7 @@ describe('VestingWallet', function () {
|
||||
});
|
||||
|
||||
it('check vesting contract', async function () {
|
||||
expect(await this.mock.owner()).to.be.equal(this.beneficiary.address);
|
||||
expect(await this.mock.owner()).to.be.equal(this.beneficiary);
|
||||
expect(await this.mock.start()).to.be.equal(this.start);
|
||||
expect(await this.mock.duration()).to.be.equal(this.duration);
|
||||
expect(await this.mock.end()).to.be.equal(this.start + this.duration);
|
||||
|
||||
Reference in New Issue
Block a user