From 5fb5e8a429511da6cd271719fcd2a43dad47d1f7 Mon Sep 17 00:00:00 2001 From: abtestingalpha <104046418+abtestingalpha@users.noreply.github.com> Date: Mon, 15 Jul 2024 12:58:30 -0400 Subject: [PATCH] feat(sdk): Adds BSC to RFQ (#2830) * Adds BSC to RFQ * swaps out bsc for arb in test --- packages/sdk-router/src/constants/chainIds.ts | 1 + packages/sdk-router/src/constants/medianTime.ts | 1 + packages/sdk-router/src/sdk.test.ts | 8 ++++---- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/sdk-router/src/constants/chainIds.ts b/packages/sdk-router/src/constants/chainIds.ts index a72208a7e8..fcdd862176 100644 --- a/packages/sdk-router/src/constants/chainIds.ts +++ b/packages/sdk-router/src/constants/chainIds.ts @@ -61,6 +61,7 @@ export const RFQ_SUPPORTED_CHAIN_IDS: number[] = [ SupportedChainId.BASE, SupportedChainId.ARBITRUM, SupportedChainId.SCROLL, + SupportedChainId.BSC, ] /** diff --git a/packages/sdk-router/src/constants/medianTime.ts b/packages/sdk-router/src/constants/medianTime.ts index eca1509f0b..d2fcd4070c 100644 --- a/packages/sdk-router/src/constants/medianTime.ts +++ b/packages/sdk-router/src/constants/medianTime.ts @@ -51,4 +51,5 @@ export const MEDIAN_TIME_RFQ = { [SupportedChainId.ARBITRUM]: 15, [SupportedChainId.BASE]: 15, [SupportedChainId.SCROLL]: 15, + [SupportedChainId.BSC]: 15, } diff --git a/packages/sdk-router/src/sdk.test.ts b/packages/sdk-router/src/sdk.test.ts index 5edbbaed05..da26f4b5a8 100644 --- a/packages/sdk-router/src/sdk.test.ts +++ b/packages/sdk-router/src/sdk.test.ts @@ -920,8 +920,8 @@ describe('SynapseSDK', () => { describe('Errors', () => { const synapse = new SynapseSDK( - [SupportedChainId.ETH, SupportedChainId.BSC], - [ethProvider, bscProvider] + [SupportedChainId.ETH, SupportedChainId.ARBITRUM], + [ethProvider, arbProvider] ) const amount = BigNumber.from(10).pow(9) @@ -983,9 +983,9 @@ describe('SynapseSDK', () => { await expect( synapse.bridgeQuote( SupportedChainId.ETH, - SupportedChainId.BSC, + SupportedChainId.ARBITRUM, ETH_USDC, - BSC_USDC, + ARB_USDC, BigNumber.from(10).pow(3) ) ).rejects.toThrow('No route found')