diff --git a/src/connectors/openocean/openocean.config.ts b/src/connectors/openocean/openocean.config.ts index 612dcc94cc..ef562b04ea 100644 --- a/src/connectors/openocean/openocean.config.ts +++ b/src/connectors/openocean/openocean.config.ts @@ -32,7 +32,7 @@ export namespace OpenoceanConfig { chainType: 'EVM', availableNetworks: [ { chain: 'avalanche', networks: ['avalanche'] }, - { chain: 'ethereum', networks: ['mainnet', 'arbitrum_one', 'optimism'] }, + { chain: 'ethereum', networks: ['mainnet', 'arbitrum', 'optimism'] }, { chain: 'polygon', networks: ['mainnet'] }, { chain: 'harmony', networks: ['mainnet'] }, { chain: 'binance-smart-chain', networks: ['mainnet'] }, diff --git a/src/connectors/openocean/openocean.ts b/src/connectors/openocean/openocean.ts index a151c2dd88..493f9c5e2a 100644 --- a/src/connectors/openocean/openocean.ts +++ b/src/connectors/openocean/openocean.ts @@ -165,7 +165,7 @@ export class Openocean implements Uniswapish { public get chainName(): string { if (this._chain === 'ethereum' && this._network === 'mainnet') { return 'eth'; - } else if (this._chain === 'ethereum' && this._network === 'arbitrum_one') { + } else if (this._chain === 'ethereum' && this._network === 'arbitrum') { return 'arbitrum'; } else if (this._chain === 'ethereum' && this._network === 'optimism') { return 'optimism'; diff --git a/src/connectors/sushiswap/sushiswap.config.ts b/src/connectors/sushiswap/sushiswap.config.ts index 01366bdc6b..8eb838bbf8 100644 --- a/src/connectors/sushiswap/sushiswap.config.ts +++ b/src/connectors/sushiswap/sushiswap.config.ts @@ -33,7 +33,7 @@ export namespace SushiswapConfig { availableNetworks: [ { chain: 'ethereum', - networks: ['mainnet', 'goerli', 'arbitrum_one'], + networks: ['mainnet', 'goerli', 'arbitrum'], }, { chain: 'avalanche', networks: ['avalanche', 'fuji'] }, { chain: 'binance-smart-chain', networks: ['mainnet', 'testnet'] }, diff --git a/src/templates/ethereum.yml b/src/templates/ethereum.yml index c917e4da64..89f25aaeee 100644 --- a/src/templates/ethereum.yml +++ b/src/templates/ethereum.yml @@ -1,9 +1,9 @@ networks: - arbitrum_one: + arbitrum: chainID: 42161 nodeURL: https://rpc.ankr.com/arbitrum tokenListType: FILE - tokenListSource: /home/gateway/conf/lists/arbitrum_one_coingecko_20230610.json + tokenListSource: /home/gateway/conf/lists/arbitrum_coingecko_20230610.json nativeCurrencySymbol: ETH gasPriceRefreshInterval: 60 arbitrum_rinkeby: diff --git a/src/templates/sushiswap.yml b/src/templates/sushiswap.yml index 9114eef20d..390c52b6ff 100644 --- a/src/templates/sushiswap.yml +++ b/src/templates/sushiswap.yml @@ -17,7 +17,7 @@ contractAddresses: sushiswapRouterAddress: '0xd9e1cE17f2641f24aE83637ab66a2cca9C378B9F' goerli: sushiswapRouterAddress: '0x1b02dA8Cb0d097eB8D57A175b88c7D8b47997506' - arbitrum_one: + arbitrum: sushiswapRouterAddress: '0x1b02dA8Cb0d097eB8D57A175b88c7D8b47997506' avalanche: avalanche: diff --git a/src/templates/uniswap.yml b/src/templates/uniswap.yml index cd00b82dc5..4e0f1df623 100644 --- a/src/templates/uniswap.yml +++ b/src/templates/uniswap.yml @@ -32,7 +32,7 @@ contractAddresses: uniswapV3SmartOrderRouterAddress: '0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45' uniswapV3NftManagerAddress: '0xC36442b4a4522E871399CD717aBDD847Ab11FE88' uniswapV3QuoterV2ContractAddress: '0x61fFE014bA17989E743c5F6cB21bF9697530B21e' - arbitrum_one: + arbitrum: uniswapV3SmartOrderRouterAddress: '0x68b3465833fb72A70ecDF485E0e4C7bD8665Fc45' uniswapV3NftManagerAddress: '0xC36442b4a4522E871399CD717aBDD847Ab11FE88' uniswapV3QuoterV2ContractAddress: '0x61fFE014bA17989E743c5F6cB21bF9697530B21e' diff --git a/test/connectors/openocean/arbitrum.openocean.routes.test.ts b/test/connectors/openocean/arbitrum.openocean.routes.test.ts index 9256c16772..7dae6a2f6e 100644 --- a/test/connectors/openocean/arbitrum.openocean.routes.test.ts +++ b/test/connectors/openocean/arbitrum.openocean.routes.test.ts @@ -15,11 +15,11 @@ beforeAll(async () => { app = express(); app.use(express.json()); - ethereum = Ethereum.getInstance('arbitrum_one'); + ethereum = Ethereum.getInstance('arbitrum'); patchEVMNonceManager(ethereum.nonceManager); await ethereum.init(); - openocean = Openocean.getInstance('ethereum', 'arbitrum_one'); + openocean = Openocean.getInstance('ethereum', 'arbitrum'); await openocean.init(); app.use('/amm', AmmRoutes.router); @@ -170,7 +170,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -198,7 +198,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -234,7 +234,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -266,7 +266,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -288,7 +288,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -310,7 +310,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -335,7 +335,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -360,7 +360,7 @@ describe('POST /amm/price', () => { .post(`/amm/price`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'bDAI', @@ -389,7 +389,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -411,7 +411,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -429,7 +429,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -460,7 +460,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -482,7 +482,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -502,7 +502,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -534,7 +534,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BITCOIN', @@ -569,7 +569,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BITCOIN', base: 'USDC', @@ -590,7 +590,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -610,7 +610,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -630,7 +630,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'USDC', base: 'BUSD', @@ -650,7 +650,7 @@ describe('POST /amm/trade', () => { .post(`/amm/trade`) .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', quote: 'BUSD', base: 'USDC', @@ -674,13 +674,13 @@ describe('POST /amm/estimateGas', () => { .post('/amm/estimateGas') .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'openocean', }) .set('Accept', 'application/json') .expect(200) .then((res: any) => { - expect(res.body.network).toEqual('arbitrum_one'); + expect(res.body.network).toEqual('arbitrum'); expect(res.body.gasPrice).toEqual(100); expect(res.body.gasCost).toEqual( gasCostInEthString(100, openocean.gasLimitEstimate) @@ -696,7 +696,7 @@ describe('POST /amm/estimateGas', () => { .post('/amm/estimateGas') .send({ chain: 'ethereum', - network: 'arbitrum_one', + network: 'arbitrum', connector: 'pangolin', }) .set('Accept', 'application/json')