From b97696558eed2da67cf3650ef51ce04d3b4de636 Mon Sep 17 00:00:00 2001 From: dan437 <80175477+dan437@users.noreply.github.com> Date: Fri, 9 Sep 2022 16:39:49 +0200 Subject: [PATCH] Replace Rinkeby with Goerli for dev testing --- app/_locales/de/messages.json | 3 --- app/_locales/el/messages.json | 3 --- app/_locales/en/messages.json | 6 +++--- app/_locales/es/messages.json | 3 --- app/_locales/es_419/messages.json | 3 --- app/_locales/fr/messages.json | 3 --- app/_locales/hi/messages.json | 3 --- app/_locales/id/messages.json | 3 --- app/_locales/ja/messages.json | 3 --- app/_locales/ko/messages.json | 3 --- app/_locales/pt/messages.json | 3 --- app/_locales/pt_BR/messages.json | 3 --- app/_locales/ru/messages.json | 3 --- app/_locales/tl/messages.json | 3 --- app/_locales/tr/messages.json | 3 --- app/_locales/vi/messages.json | 3 --- app/_locales/zh/messages.json | 3 --- app/_locales/zh_CN/messages.json | 3 --- shared/constants/swaps.js | 30 ++++++++++++++--------------- ui/ducks/swaps/swaps.test.js | 6 +++--- ui/hooks/useTokensToSearch.js | 10 +++++++++- ui/pages/swaps/fee-card/fee-card.js | 6 +++--- ui/pages/swaps/swaps.util.js | 14 +++++++------- ui/pages/swaps/swaps.util.test.js | 18 ++++++++--------- 24 files changed, 49 insertions(+), 92 deletions(-) diff --git a/app/_locales/de/messages.json b/app/_locales/de/messages.json index 8cf474b97f4a..7bd41e8446b8 100644 --- a/app/_locales/de/messages.json +++ b/app/_locales/de/messages.json @@ -1974,9 +1974,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/el/messages.json b/app/_locales/el/messages.json index a1aef22e6909..d6545839a8f3 100644 --- a/app/_locales/el/messages.json +++ b/app/_locales/el/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Πολύγωνο" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/en/messages.json b/app/_locales/en/messages.json index 94c9e49f3732..9cee321cc35b 100644 --- a/app/_locales/en/messages.json +++ b/app/_locales/en/messages.json @@ -2127,12 +2127,12 @@ "networkNameEthereum": { "message": "Ethereum" }, + "networkNameGoerli": { + "message": "Goerli" + }, "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/es/messages.json b/app/_locales/es/messages.json index 7422d37b72ea..ca5d01a6bfc0 100644 --- a/app/_locales/es/messages.json +++ b/app/_locales/es/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Red de prueba" }, diff --git a/app/_locales/es_419/messages.json b/app/_locales/es_419/messages.json index 727b45206f89..9aca362edffe 100644 --- a/app/_locales/es_419/messages.json +++ b/app/_locales/es_419/messages.json @@ -1703,9 +1703,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Red de prueba" }, diff --git a/app/_locales/fr/messages.json b/app/_locales/fr/messages.json index 0be0b6ed4b71..4f099a565c60 100644 --- a/app/_locales/fr/messages.json +++ b/app/_locales/fr/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/hi/messages.json b/app/_locales/hi/messages.json index 8996fe61c324..6c6ac60e42c1 100644 --- a/app/_locales/hi/messages.json +++ b/app/_locales/hi/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "बहुभुज" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/id/messages.json b/app/_locales/id/messages.json index cfa90d18676b..49a4867ad58d 100644 --- a/app/_locales/id/messages.json +++ b/app/_locales/id/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/ja/messages.json b/app/_locales/ja/messages.json index 6565d4c911d0..3042bad67799 100644 --- a/app/_locales/ja/messages.json +++ b/app/_locales/ja/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "テストネット" }, diff --git a/app/_locales/ko/messages.json b/app/_locales/ko/messages.json index 6db8481c1735..b9cd8aca3de2 100644 --- a/app/_locales/ko/messages.json +++ b/app/_locales/ko/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "테스트넷" }, diff --git a/app/_locales/pt/messages.json b/app/_locales/pt/messages.json index 90d2afdace42..dc235947cd2a 100644 --- a/app/_locales/pt/messages.json +++ b/app/_locales/pt/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/pt_BR/messages.json b/app/_locales/pt_BR/messages.json index b11ca743fa64..36ab85551023 100644 --- a/app/_locales/pt_BR/messages.json +++ b/app/_locales/pt_BR/messages.json @@ -1687,9 +1687,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/ru/messages.json b/app/_locales/ru/messages.json index 6d94c9fa5780..998e2b79270e 100644 --- a/app/_locales/ru/messages.json +++ b/app/_locales/ru/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Тестовая сеть" }, diff --git a/app/_locales/tl/messages.json b/app/_locales/tl/messages.json index 4a4182970560..fe28433051f2 100644 --- a/app/_locales/tl/messages.json +++ b/app/_locales/tl/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/tr/messages.json b/app/_locales/tr/messages.json index f9de67fe460b..8d91728a2ee5 100644 --- a/app/_locales/tr/messages.json +++ b/app/_locales/tr/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/vi/messages.json b/app/_locales/vi/messages.json index fed68816f5de..f7577b291bb0 100644 --- a/app/_locales/vi/messages.json +++ b/app/_locales/vi/messages.json @@ -2001,9 +2001,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Mạng thử nghiệm" }, diff --git a/app/_locales/zh/messages.json b/app/_locales/zh/messages.json index 72321b1e7e86..70610a5bceb5 100644 --- a/app/_locales/zh/messages.json +++ b/app/_locales/zh/messages.json @@ -2004,9 +2004,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/app/_locales/zh_CN/messages.json b/app/_locales/zh_CN/messages.json index 1a0e14dda9a8..4058548aa57f 100644 --- a/app/_locales/zh_CN/messages.json +++ b/app/_locales/zh_CN/messages.json @@ -1654,9 +1654,6 @@ "networkNamePolygon": { "message": "Polygon" }, - "networkNameRinkeby": { - "message": "Rinkeby" - }, "networkNameTestnet": { "message": "Testnet" }, diff --git a/shared/constants/swaps.js b/shared/constants/swaps.js index 8482709caf09..9bc14874ef7f 100644 --- a/shared/constants/swaps.js +++ b/shared/constants/swaps.js @@ -9,7 +9,7 @@ import { POLYGON_CHAIN_ID, MATIC_SYMBOL, MATIC_TOKEN_IMAGE_URL, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, AVALANCHE_CHAIN_ID, AVALANCHE_SYMBOL, AVAX_TOKEN_IMAGE_URL, @@ -66,7 +66,7 @@ export const TEST_ETH_SWAPS_TOKEN_OBJECT = { iconUrl: TEST_ETH_TOKEN_IMAGE_URL, }; -export const RINKEBY_SWAPS_TOKEN_OBJECT = { +export const GOERLI_SWAPS_TOKEN_OBJECT = { symbol: ETH_SYMBOL, name: 'Ether', address: DEFAULT_TOKEN_ADDRESS, @@ -90,8 +90,8 @@ const AVALANCHE_CONTRACT_ADDRESS = '0x1a1ec25dc08e98e5e93f1104b5e5cdd298707d31'; export const WETH_CONTRACT_ADDRESS = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'; -export const WETH_RINKEBY_CONTRACT_ADDRESS = - '0xc778417e063141139fce010982780140aa0cd5ab'; +export const WETH_GOERLI_CONTRACT_ADDRESS = + '0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6'; export const WBNB_CONTRACT_ADDRESS = '0xbb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c'; export const WMATIC_CONTRACT_ADDRESS = @@ -110,7 +110,7 @@ export const GAS_DEV_API_BASE_URL = const BSC_DEFAULT_BLOCK_EXPLORER_URL = 'https://bscscan.com/'; const MAINNET_DEFAULT_BLOCK_EXPLORER_URL = 'https://etherscan.io/'; -const RINKEBY_DEFAULT_BLOCK_EXPLORER_URL = 'https://rinkeby.etherscan.io/'; +const GOERLI_DEFAULT_BLOCK_EXPLORER_URL = 'https://goerli.etherscan.io/'; const POLYGON_DEFAULT_BLOCK_EXPLORER_URL = 'https://polygonscan.com/'; const AVALANCHE_DEFAULT_BLOCK_EXPLORER_URL = 'https://snowtrace.io/'; @@ -124,12 +124,12 @@ export const ALLOWED_PROD_SWAPS_CHAIN_IDS = [ export const ALLOWED_DEV_SWAPS_CHAIN_IDS = [ ...ALLOWED_PROD_SWAPS_CHAIN_IDS, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, ]; export const ALLOWED_SMART_TRANSACTIONS_CHAIN_IDS = [ MAINNET_CHAIN_ID, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, ]; export const SWAPS_CHAINID_CONTRACT_ADDRESS_MAP = { @@ -137,7 +137,7 @@ export const SWAPS_CHAINID_CONTRACT_ADDRESS_MAP = { [SWAPS_TESTNET_CHAIN_ID]: TESTNET_CONTRACT_ADDRESS, [BSC_CHAIN_ID]: BSC_CONTRACT_ADDRESS, [POLYGON_CHAIN_ID]: POLYGON_CONTRACT_ADDRESS, - [RINKEBY_CHAIN_ID]: TESTNET_CONTRACT_ADDRESS, + [GOERLI_CHAIN_ID]: TESTNET_CONTRACT_ADDRESS, [AVALANCHE_CHAIN_ID]: AVALANCHE_CONTRACT_ADDRESS, }; @@ -146,7 +146,7 @@ export const SWAPS_WRAPPED_TOKENS_ADDRESSES = { [SWAPS_TESTNET_CHAIN_ID]: WETH_CONTRACT_ADDRESS, [BSC_CHAIN_ID]: WBNB_CONTRACT_ADDRESS, [POLYGON_CHAIN_ID]: WMATIC_CONTRACT_ADDRESS, - [RINKEBY_CHAIN_ID]: WETH_RINKEBY_CONTRACT_ADDRESS, + [GOERLI_CHAIN_ID]: WETH_GOERLI_CONTRACT_ADDRESS, [AVALANCHE_CHAIN_ID]: WAVAX_CONTRACT_ADDRESS, }; @@ -159,9 +159,9 @@ export const ALLOWED_CONTRACT_ADDRESSES = { SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[SWAPS_TESTNET_CHAIN_ID], SWAPS_WRAPPED_TOKENS_ADDRESSES[SWAPS_TESTNET_CHAIN_ID], ], - [RINKEBY_CHAIN_ID]: [ - SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[RINKEBY_CHAIN_ID], - SWAPS_WRAPPED_TOKENS_ADDRESSES[RINKEBY_CHAIN_ID], + [GOERLI_CHAIN_ID]: [ + SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[GOERLI_CHAIN_ID], + SWAPS_WRAPPED_TOKENS_ADDRESSES[GOERLI_CHAIN_ID], ], [BSC_CHAIN_ID]: [ SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[BSC_CHAIN_ID], @@ -182,7 +182,7 @@ export const SWAPS_CHAINID_DEFAULT_TOKEN_MAP = { [SWAPS_TESTNET_CHAIN_ID]: TEST_ETH_SWAPS_TOKEN_OBJECT, [BSC_CHAIN_ID]: BNB_SWAPS_TOKEN_OBJECT, [POLYGON_CHAIN_ID]: MATIC_SWAPS_TOKEN_OBJECT, - [RINKEBY_CHAIN_ID]: RINKEBY_SWAPS_TOKEN_OBJECT, + [GOERLI_CHAIN_ID]: GOERLI_SWAPS_TOKEN_OBJECT, [AVALANCHE_CHAIN_ID]: AVAX_SWAPS_TOKEN_OBJECT, }; @@ -190,14 +190,14 @@ export const SWAPS_CHAINID_DEFAULT_BLOCK_EXPLORER_URL_MAP = { [BSC_CHAIN_ID]: BSC_DEFAULT_BLOCK_EXPLORER_URL, [MAINNET_CHAIN_ID]: MAINNET_DEFAULT_BLOCK_EXPLORER_URL, [POLYGON_CHAIN_ID]: POLYGON_DEFAULT_BLOCK_EXPLORER_URL, - [RINKEBY_CHAIN_ID]: RINKEBY_DEFAULT_BLOCK_EXPLORER_URL, + [GOERLI_CHAIN_ID]: GOERLI_DEFAULT_BLOCK_EXPLORER_URL, [AVALANCHE_CHAIN_ID]: AVALANCHE_DEFAULT_BLOCK_EXPLORER_URL, }; export const ETHEREUM = 'ethereum'; export const POLYGON = 'polygon'; export const BSC = 'bsc'; -export const RINKEBY = 'rinkeby'; +export const GOERLI = 'goerli'; export const AVALANCHE = 'avalanche'; export const SWAPS_CLIENT_ID = 'extension'; diff --git a/ui/ducks/swaps/swaps.test.js b/ui/ducks/swaps/swaps.test.js index 027e4d479664..595782a2e46a 100644 --- a/ui/ducks/swaps/swaps.test.js +++ b/ui/ducks/swaps/swaps.test.js @@ -5,7 +5,7 @@ import { setSwapsLiveness, setSwapsFeatureFlags } from '../../store/actions'; import { setStorageItem } from '../../helpers/utils/storage-helpers'; import { MAINNET_CHAIN_ID, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, BSC_CHAIN_ID, POLYGON_CHAIN_ID, } from '../../../shared/constants/network'; @@ -280,9 +280,9 @@ describe('Ducks - Swaps', () => { expect(swaps.getSmartTransactionsEnabled(state)).toBe(false); }); - it('returns true if feature flag is enabled, not a HW and is Rinkeby network', () => { + it('returns true if feature flag is enabled, not a HW and is Goerli network', () => { const state = createSwapsMockStore(); - state.metamask.provider.chainId = RINKEBY_CHAIN_ID; + state.metamask.provider.chainId = GOERLI_CHAIN_ID; expect(swaps.getSmartTransactionsEnabled(state)).toBe(true); }); diff --git a/ui/hooks/useTokensToSearch.js b/ui/hooks/useTokensToSearch.js index 44c4682e551d..94434f309bf3 100644 --- a/ui/hooks/useTokensToSearch.js +++ b/ui/hooks/useTokensToSearch.js @@ -26,6 +26,7 @@ import { BSC_CHAIN_ID, POLYGON_CHAIN_ID, AVALANCHE_CHAIN_ID, + GOERLI_CHAIN_ID, } from '../../shared/constants/network'; import { useEqualityCheck } from './useEqualityCheck'; @@ -66,13 +67,20 @@ export function getRenderableTokenData( ) : ''; + const chainIdForTokenIcons = + chainId === GOERLI_CHAIN_ID ? MAINNET_CHAIN_ID : chainId; + const tokenIconUrl = (symbol === ETH_SYMBOL && chainId === MAINNET_CHAIN_ID) || + (symbol === ETH_SYMBOL && chainId === GOERLI_CHAIN_ID) || (symbol === BNB_SYMBOL && chainId === BSC_CHAIN_ID) || (symbol === MATIC_SYMBOL && chainId === POLYGON_CHAIN_ID) || (symbol === AVALANCHE_SYMBOL && chainId === AVALANCHE_CHAIN_ID) ? iconUrl - : formatIconUrlWithProxy({ chainId, tokenAddress: address || '' }); + : formatIconUrlWithProxy({ + chainId: chainIdForTokenIcons, + tokenAddress: address || '', + }); const usedIconUrl = tokenIconUrl || token?.image; return { diff --git a/ui/pages/swaps/fee-card/fee-card.js b/ui/pages/swaps/fee-card/fee-card.js index e04bc5ad05aa..c2bb8c3b802c 100644 --- a/ui/pages/swaps/fee-card/fee-card.js +++ b/ui/pages/swaps/fee-card/fee-card.js @@ -7,7 +7,7 @@ import { BSC_CHAIN_ID, LOCALHOST_CHAIN_ID, POLYGON_CHAIN_ID, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, AVALANCHE_CHAIN_ID, } from '../../../../shared/constants/network'; import TransactionDetail from '../../../components/app/transaction-detail/transaction-detail.component'; @@ -48,8 +48,8 @@ export default function FeeCard({ return t('networkNamePolygon'); case LOCALHOST_CHAIN_ID: return t('networkNameTestnet'); - case RINKEBY_CHAIN_ID: - return t('networkNameRinkeby'); + case GOERLI_CHAIN_ID: + return t('networkNameGoerli'); case AVALANCHE_CHAIN_ID: return t('networkNameAvalanche'); default: diff --git a/ui/pages/swaps/swaps.util.js b/ui/pages/swaps/swaps.util.js index 71bb2669f324..29ba98959e1b 100644 --- a/ui/pages/swaps/swaps.util.js +++ b/ui/pages/swaps/swaps.util.js @@ -8,7 +8,7 @@ import { ETHEREUM, POLYGON, BSC, - RINKEBY, + GOERLI, AVALANCHE, SWAPS_API_V2_BASE_URL, SWAPS_DEV_API_V2_BASE_URL, @@ -26,7 +26,7 @@ import { BSC_CHAIN_ID, POLYGON_CHAIN_ID, LOCALHOST_CHAIN_ID, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, ETH_SYMBOL, AVALANCHE_CHAIN_ID, } from '../../../shared/constants/network'; @@ -82,7 +82,7 @@ const getBaseUrlForNewSwapsApi = (type, chainId) => { return `${v2ApiBaseUrl}/networks/${chainIdDecimal}`; }; -const TEST_CHAIN_IDS = [RINKEBY_CHAIN_ID, LOCALHOST_CHAIN_ID]; +const TEST_CHAIN_IDS = [GOERLI_CHAIN_ID, LOCALHOST_CHAIN_ID]; export const getBaseApi = function (type, chainId = MAINNET_CHAIN_ID) { // eslint-disable-next-line no-param-reassign @@ -874,8 +874,8 @@ export const getNetworkNameByChainId = (chainId) => { return BSC; case POLYGON_CHAIN_ID: return POLYGON; - case RINKEBY_CHAIN_ID: - return RINKEBY; + case GOERLI_CHAIN_ID: + return GOERLI; case AVALANCHE_CHAIN_ID: return AVALANCHE; default: @@ -892,8 +892,8 @@ export const getNetworkNameByChainId = (chainId) => { */ export const getSwapsLivenessForNetwork = (swapsFeatureFlags = {}, chainId) => { const networkName = getNetworkNameByChainId(chainId); - // Use old APIs for testnet and Rinkeby. - if ([LOCALHOST_CHAIN_ID, RINKEBY_CHAIN_ID].includes(chainId)) { + // Use old APIs for testnet and Goerli. + if ([LOCALHOST_CHAIN_ID, GOERLI_CHAIN_ID].includes(chainId)) { return { swapsFeatureIsLive: true, }; diff --git a/ui/pages/swaps/swaps.util.test.js b/ui/pages/swaps/swaps.util.test.js index 755998f53f69..b99274b648c1 100644 --- a/ui/pages/swaps/swaps.util.test.js +++ b/ui/pages/swaps/swaps.util.test.js @@ -5,7 +5,7 @@ import { BSC_CHAIN_ID, POLYGON_CHAIN_ID, LOCALHOST_CHAIN_ID, - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, KOVAN_CHAIN_ID, AVALANCHE_CHAIN_ID, ETH_SYMBOL, @@ -19,7 +19,7 @@ import { ETHEREUM, POLYGON, BSC, - RINKEBY, + GOERLI, AVALANCHE, } from '../../../shared/constants/swaps'; import { @@ -273,11 +273,11 @@ describe('Swaps Util', () => { ).toBe(true); }); - it('returns true if "to" is Rinkeby contract address on Rinkeby network', () => { + it('returns true if "to" is Goerli contract address on Goerli network', () => { usedTradeTxParams.to = - SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[RINKEBY_CHAIN_ID]; + SWAPS_CHAINID_CONTRACT_ADDRESS_MAP[GOERLI_CHAIN_ID]; expect( - isContractAddressValid(usedTradeTxParams.to, RINKEBY_CHAIN_ID), + isContractAddressValid(usedTradeTxParams.to, GOERLI_CHAIN_ID), ).toBe(true); }); @@ -317,8 +317,8 @@ describe('Swaps Util', () => { expect(getNetworkNameByChainId(POLYGON_CHAIN_ID)).toBe(POLYGON); }); - it('returns "rinkeby" for Rinkeby chain ID', () => { - expect(getNetworkNameByChainId(RINKEBY_CHAIN_ID)).toBe(RINKEBY); + it('returns "goerli" for Goerli chain ID', () => { + expect(getNetworkNameByChainId(GOERLI_CHAIN_ID)).toBe(GOERLI); }); it('returns "avalanche" for Avalanche chain ID', () => { @@ -343,14 +343,14 @@ describe('Swaps Util', () => { ).toMatchObject(expectedSwapsLiveness); }); - it('returns info that Swaps are enabled and cannot use API v2 for Rinkeby chain ID', () => { + it('returns info that Swaps are enabled and cannot use API v2 for Goerli chain ID', () => { const expectedSwapsLiveness = { swapsFeatureIsLive: true, }; expect( getSwapsLivenessForNetwork( MOCKS.createFeatureFlagsResponse(), - RINKEBY_CHAIN_ID, + GOERLI_CHAIN_ID, ), ).toMatchObject(expectedSwapsLiveness); });