@@ -12,16 +12,20 @@ import (
1212 "testing"
1313
1414 "github.com/aptos-labs/aptos-go-sdk"
15- "github.com/block-vision/sui-go-sdk/sui"
1615 "github.com/ethereum/go-ethereum/ethclient"
1716 "github.com/gagliardetto/solana-go/rpc"
1817 "github.com/gagliardetto/solana-go/rpc/ws"
1918 "github.com/joho/godotenv"
2019 "github.com/stretchr/testify/require"
2120 "github.com/xssnick/tonutils-go/ton"
2221
22+ "github.com/smartcontractkit/chainlink-common/pkg/logger"
2323 tonchain "github.com/smartcontractkit/chainlink-ton/pkg/ton/chain"
2424
25+ cslclient "github.com/smartcontractkit/chainlink-sui/relayer/client"
26+
27+ suisdk "github.com/smartcontractkit/mcms/sdk/sui"
28+
2529 "github.com/smartcontractkit/chainlink-testing-framework/framework"
2630 "github.com/smartcontractkit/chainlink-testing-framework/framework/components/blockchain"
2731 "github.com/smartcontractkit/freeport"
@@ -60,7 +64,7 @@ type TestSetup struct {
6064 AptosRPCClient * aptos.NodeClient
6165 SolanaBlockchain * blockchain.Output
6266 AptosBlockchain * blockchain.Output
63- SuiClient sui. ISuiAPI
67+ SuiClient cslclient. BindingsClient
6468 SuiBlockchain * blockchain.Output
6569 SuiNodeURL string
6670 TonClient * ton.APIClient
@@ -187,14 +191,17 @@ func InitializeSharedTestSetup(t *testing.T) *TestSetup {
187191 }
188192
189193 var (
190- suiClient sui. ISuiAPI
194+ suiClient cslclient. BindingsClient
191195 suiBlockchainOutput * blockchain.Output
192196 suiNodeURL string
193197 )
198+ suiLog := logger .Test (t )
194199 if in .Settings .LocalSuiNodeURL != "" {
195200 // Connect to local Sui node (highest priority)
196201 suiNodeURL = in .Settings .LocalSuiNodeURL
197- suiClient = sui .NewSuiClient (suiNodeURL )
202+ var clientErr error
203+ suiClient , clientErr = suisdk .NewBindingsClientFromNodeURL (suiLog , suiNodeURL , "" )
204+ require .NoError (t , clientErr , "Failed to create Sui gRPC client" )
198205 t .Logf ("Connected to local Sui node @ %s" , suiNodeURL )
199206 } else if in .SuiChain != nil {
200207 // Use blockchain network setup (fallback)
@@ -208,10 +215,12 @@ func InitializeSharedTestSetup(t *testing.T) *TestSetup {
208215 require .NoError (t , err , "Failed to initialize Sui blockchain" )
209216
210217 suiNodeURL = suiBlockchainOutput .Nodes [0 ].ExternalHTTPUrl
211- suiClient = sui .NewSuiClient (suiNodeURL )
218+ var clientErr error
219+ suiClient , clientErr = suisdk .NewBindingsClientFromNodeURL (suiLog , suiNodeURL , "" )
220+ require .NoError (t , clientErr , "Failed to create Sui gRPC client" )
212221
213222 // Test liveness, will also fetch ChainID
214- t .Logf ("Initialized Sui RPC client @ %s" , suiNodeURL )
223+ t .Logf ("Initialized Sui gRPC client @ %s" , suiNodeURL )
215224 }
216225
217226 var (
0 commit comments