@@ -5,17 +5,15 @@ import {
5
5
routes ,
6
6
} from "@wormhole-foundation/sdk-connect" ;
7
7
8
- import * as testing from "@wormhole-foundation/sdk-definitions/testing" ;
9
-
10
8
import "@wormhole-foundation/sdk-definitions-ntt" ;
11
9
import "@wormhole-foundation/sdk-evm-ntt" ;
12
10
import "@wormhole-foundation/sdk-solana-ntt" ;
13
11
14
12
import { EvmPlatform } from "@wormhole-foundation/sdk-evm" ;
15
13
import { SolanaPlatform } from "@wormhole-foundation/sdk-solana" ;
14
+ import { nttAutomaticRoute } from "../src/automatic.js" ;
16
15
import { nttManualRoute } from "../src/manual.js" ;
17
16
import { NttRoute } from "../src/types.js" ;
18
- import { nttAutomaticRoute } from "../src/automatic.js" ;
19
17
20
18
const SOL_TOKEN = "EetppHswYvV1jjRWoQKC1hejdeBDHR9NNzNtCyRQfrrQ" ;
21
19
const SEPOLIA_TOKEN = "0x738141EFf659625F2eAD4feECDfCD94155C67f18" ;
@@ -92,14 +90,12 @@ describe("Manual Route Tests", function () {
92
90
let found : routes . ManualRoute < Network > ;
93
91
it ( "Should resolve a given route request" , async function ( ) {
94
92
const request = await routes . RouteTransferRequest . create ( wh , {
95
- from : testing . utils . makeChainAddress ( "Solana" ) ,
96
- to : testing . utils . makeChainAddress ( "Sepolia" ) ,
97
93
source : Wormhole . tokenId ( "Solana" , SOL_TOKEN ) ,
98
94
destination : Wormhole . tokenId ( "Sepolia" , SEPOLIA_TOKEN ) ,
99
95
} ) ;
100
96
const foundRoutes = await resolver . findRoutes ( request ) ;
101
97
expect ( foundRoutes ) . toHaveLength ( 1 ) ;
102
- expect ( foundRoutes [ 0 ] ! . request . from . chain ) . toEqual ( "Solana" ) ;
98
+ expect ( foundRoutes [ 0 ] ! . request . fromChain . chain ) . toEqual ( "Solana" ) ;
103
99
104
100
const rt = foundRoutes [ 0 ] ! ;
105
101
if ( ! routes . isManual ( rt ) ) throw new Error ( "Expected manual route" ) ;
@@ -185,14 +181,12 @@ describe("Automatic Route Tests", function () {
185
181
let found : routes . AutomaticRoute < Network > ;
186
182
it ( "Should resolve a given route request" , async function ( ) {
187
183
const request = await routes . RouteTransferRequest . create ( wh , {
188
- from : testing . utils . makeChainAddress ( "Solana" ) ,
189
- to : testing . utils . makeChainAddress ( "Sepolia" ) ,
190
184
source : Wormhole . tokenId ( "Solana" , SOL_TOKEN ) ,
191
185
destination : Wormhole . tokenId ( "Sepolia" , SEPOLIA_TOKEN ) ,
192
186
} ) ;
193
187
const foundRoutes = await resolver . findRoutes ( request ) ;
194
188
expect ( foundRoutes ) . toHaveLength ( 1 ) ;
195
- expect ( foundRoutes [ 0 ] ! . request . from . chain ) . toEqual ( "Solana" ) ;
189
+ expect ( foundRoutes [ 0 ] ! . request . fromChain . chain ) . toEqual ( "Solana" ) ;
196
190
197
191
const rt = foundRoutes [ 0 ] ! ;
198
192
if ( ! routes . isAutomatic ( rt ) ) throw new Error ( "Expected automatic route" ) ;
0 commit comments