diff --git a/packages/ua-utils-evm-hardhat-test/test/task/getDefaultConfig.test.ts b/packages/ua-utils-evm-hardhat-test/test/task/getDefaultConfig.test.ts index f89443622..c27ecdd65 100644 --- a/packages/ua-utils-evm-hardhat-test/test/task/getDefaultConfig.test.ts +++ b/packages/ua-utils-evm-hardhat-test/test/task/getDefaultConfig.test.ts @@ -20,29 +20,11 @@ describe('task: getDefaultConfig', () => { const sendUln302 = await contractFactory({ contractName: 'SendUln302', eid: localEid }) const receiveUln302 = await contractFactory({ contractName: 'ReceiveUln302', eid: localEid }) - // verify defaultSendLibrary & defaultReceiveLibrary expect(defaultConfig.defaultSendLibrary).toEqual(sendUln302.contract.address) expect(defaultConfig.defaultReceiveLibrary).toEqual(receiveUln302.contract.address) - - // verify sendUln - expect(defaultConfig.sendExecutorConfig.maxMessageSize).toEqual(defaultExecutorConfig.maxMessageSize) - expect(defaultConfig.sendExecutorConfig.executor).toEqual(defaultExecutorConfig.executor) - expect(defaultConfig.sendUlnConfig.confirmations.toString()).toEqual( - defaultUlnConfig.confirmations.toString() - ) - expect(defaultConfig.sendUlnConfig.optionalDVNThreshold).toEqual(defaultUlnConfig.optionalDVNThreshold) - expect(defaultConfig.sendUlnConfig.requiredDVNs).toEqual(defaultUlnConfig.requiredDVNs) - expect(defaultConfig.sendUlnConfig.optionalDVNs).toEqual(defaultUlnConfig.optionalDVNs) - - // verify receiveUln - expect(defaultConfig.receiveUlnConfig.confirmations.toString()).toEqual( - defaultUlnConfig.confirmations.toString() - ) - expect(defaultConfig.receiveUlnConfig.optionalDVNThreshold).toEqual( - defaultUlnConfig.optionalDVNThreshold - ) - expect(defaultConfig.receiveUlnConfig.requiredDVNs).toEqual(defaultUlnConfig.requiredDVNs) - expect(defaultConfig.receiveUlnConfig.optionalDVNs).toEqual(defaultUlnConfig.optionalDVNs) + expect(defaultConfig.sendExecutorConfig).toEqual(defaultExecutorConfig) + expect(defaultConfig.sendUlnConfig).toEqual(defaultUlnConfig) + expect(defaultConfig.receiveUlnConfig).toEqual(defaultUlnConfig) } } }) diff --git a/packages/ua-utils-evm-hardhat-test/test/task/getOAppConfig.test.ts b/packages/ua-utils-evm-hardhat-test/test/task/getOAppConfig.test.ts index 9543b0850..e8c5556a4 100644 --- a/packages/ua-utils-evm-hardhat-test/test/task/getOAppConfig.test.ts +++ b/packages/ua-utils-evm-hardhat-test/test/task/getOAppConfig.test.ts @@ -1,8 +1,6 @@ -import { describe } from 'mocha' import { defaultExecutorConfig, defaultUlnConfig, setupDefaultEndpoint } from '../__utils__/endpoint' import { createContractFactory, getEidForNetworkName } from '@layerzerolabs/utils-evm-hardhat' import hre from 'hardhat' -import { expect, assert } from 'chai' import { AddressZero } from '@ethersproject/constants' describe('task: getOAppConfig', () => { @@ -18,7 +16,6 @@ describe('task: getOAppConfig', () => { addresses: addresses.toString(), }) const contractFactory = createContractFactory() - for (const localNetwork of networks) { const localEid = getEidForNetworkName(localNetwork) for (const remoteNetwork of networks) { @@ -28,29 +25,11 @@ describe('task: getOAppConfig', () => { const sendUln302 = await contractFactory({ contractName: 'SendUln302', eid: localEid }) const receiveUln302 = await contractFactory({ contractName: 'ReceiveUln302', eid: localEid }) - // verify defaultSendLibrary & defaultReceiveLibrary - expect(defaultConfig.defaultSendLibrary).to.eql(sendUln302.contract.address) - expect(defaultConfig.defaultReceiveLibrary).to.eql(receiveUln302.contract.address) - - // verify sendUln - expect(defaultConfig.sendExecutorConfig.maxMessageSize).to.eql(defaultExecutorConfig.maxMessageSize) - expect(defaultConfig.sendExecutorConfig.executor).to.eql(defaultExecutorConfig.executor) - expect(defaultConfig.sendUlnConfig.confirmations.toString()).to.eql( - defaultUlnConfig.confirmations.toString() - ) - expect(defaultConfig.sendUlnConfig.optionalDVNThreshold).to.eql(defaultUlnConfig.optionalDVNThreshold) - expect(defaultConfig.sendUlnConfig.requiredDVNs).to.eql(defaultUlnConfig.requiredDVNs) - expect(defaultConfig.sendUlnConfig.optionalDVNs).to.eql(defaultUlnConfig.optionalDVNs) - - // verify receiveUln - expect(defaultConfig.receiveUlnConfig.confirmations.toString()).to.eql( - defaultUlnConfig.confirmations.toString() - ) - expect(defaultConfig.receiveUlnConfig.optionalDVNThreshold).to.eql( - defaultUlnConfig.optionalDVNThreshold - ) - expect(defaultConfig.receiveUlnConfig.requiredDVNs).to.eql(defaultUlnConfig.requiredDVNs) - expect(defaultConfig.receiveUlnConfig.optionalDVNs).to.eql(defaultUlnConfig.optionalDVNs) + expect(defaultConfig.defaultSendLibrary).toEqual(sendUln302.contract.address) + expect(defaultConfig.defaultReceiveLibrary).toEqual(receiveUln302.contract.address) + expect(defaultConfig.sendExecutorConfig).toEqual(defaultExecutorConfig) + expect(defaultConfig.sendUlnConfig).toEqual(defaultUlnConfig) + expect(defaultConfig.receiveUlnConfig).toEqual(defaultUlnConfig) } } })