Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions e2e/tests/setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ type TestSetup struct {
SolanaBlockchain *blockchain.Output
AptosBlockchain *blockchain.Output
SuiClient sui.ISuiAPI
SuiNodeUrl string
SuiBlockchain *blockchain.Output
Config
}
Expand Down Expand Up @@ -180,10 +181,12 @@ func InitializeSharedTestSetup(t *testing.T) *TestSetup {
var (
suiClient sui.ISuiAPI
suiBlockchainOutput *blockchain.Output
suiNodeUrl string
)
if in.Settings.LocalSuiNodeURL != "" {
// Connect to local Sui node (highest priority)
suiClient = sui.NewSuiClient(in.Settings.LocalSuiNodeURL)
suiNodeUrl = in.Settings.LocalSuiNodeURL
t.Logf("Connected to local Sui node @ %s", in.Settings.LocalSuiNodeURL)
} else if in.SuiChain != nil {
// Use blockchain network setup (fallback)
Expand All @@ -198,6 +201,7 @@ func InitializeSharedTestSetup(t *testing.T) *TestSetup {

nodeURL := suiBlockchainOutput.Nodes[0].ExternalHTTPUrl
suiClient = sui.NewSuiClient(nodeURL)
suiNodeUrl = nodeURL

// Test liveness, will also fetch ChainID
t.Logf("Initialized Sui RPC client @ %s", nodeURL)
Expand All @@ -213,6 +217,7 @@ func InitializeSharedTestSetup(t *testing.T) *TestSetup {
AptosBlockchain: aptosBlockchainOutput,
SuiClient: suiClient,
SuiBlockchain: suiBlockchainOutput,
SuiNodeUrl: suiNodeUrl,
Config: *in,
}
})
Expand Down
10 changes: 6 additions & 4 deletions e2e/tests/sui/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@ type TestSuite struct {
suite.Suite
e2e.TestSetup

client sui.ISuiAPI
signer bindutils.SuiSigner
client sui.ISuiAPI
signer bindutils.SuiSigner
suiNodeUrl string

chainSelector types.ChainSelector

Expand Down Expand Up @@ -75,6 +76,7 @@ func (s *TestSuite) SetupSuite() {

// Set up Sui client
s.client = s.SuiClient
s.suiNodeUrl = s.SuiNodeUrl
// TODO: Find funded accounts
s.signer = testSigner
s.chainSelector = types.ChainSelector(cselectors.SUI_TESTNET.Selector)
Expand All @@ -86,7 +88,7 @@ func (s *TestSuite) DeployMCMSContract() {
Signer: s.signer,
GasBudget: &gasBudget,
WaitForExecution: true,
}, s.client)
}, s.client, s.suiNodeUrl)
s.Require().NoError(err, "Failed to publish MCMS package")
s.mcmsPackageID = mcmsPackage.Address()
s.mcms = mcmsPackage.MCMS()
Expand Down Expand Up @@ -129,7 +131,7 @@ func (s *TestSuite) DeployMCMSUserContract() {
Signer: s.signer,
GasBudget: &gasBudget,
WaitForExecution: true,
}, s.client, s.mcmsPackageID, signerAddress)
}, s.client, s.mcmsPackageID, signerAddress, s.suiNodeUrl)
s.Require().NoError(err, "Failed to publish MCMS user package")

s.mcmsUserPackageID = mcmsUserPackage.Address()
Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/sui/mcms_user_upgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ func RunMCMSUserUpgradeProposal(s *MCMSUserUpgradeTestSuite) {
"mcms": s.mcmsPackageID,
"mcms_owner": signerAddr,
"mcms_test": "0x0",
})
}, false, s.suiNodeUrl)
s.Require().NoError(err)

newAddress := executeUpgradePTB(s.T(), s, compiledPackage, proposerConfig)
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ require (
github.com/smartcontractkit/chainlink-aptos v0.0.0-20251024142440-51f2ad2652a2
github.com/smartcontractkit/chainlink-ccip/chains/solana v0.0.0-20250805210128-7f8a0f403c3a
github.com/smartcontractkit/chainlink-ccip/chains/solana/gobindings v0.0.0-20250805210128-7f8a0f403c3a
github.com/smartcontractkit/chainlink-sui v0.0.0-20251104205009-00bd79b81471
github.com/smartcontractkit/chainlink-sui v0.0.0-20251230103558-1e068e723c05
github.com/smartcontractkit/chainlink-testing-framework/framework v0.12.1
github.com/smartcontractkit/freeport v0.1.3-0.20250716200817-cb5dfd0e369e
github.com/spf13/cast v1.10.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -642,8 +642,8 @@ github.com/smartcontractkit/chainlink-common/pkg/chipingress v0.0.4 h1:hvqATtrZ0
github.com/smartcontractkit/chainlink-common/pkg/chipingress v0.0.4/go.mod h1:eKGyfTKzr0/PeR7qKN4l2FcW9p+HzyKUwAfGhm/5YZc=
github.com/smartcontractkit/chainlink-protos/cre/go v0.0.0-20250911124514-5874cc6d62b2 h1:1/KdO5AbUr3CmpLjMPuJXPo2wHMbfB8mldKLsg7D4M8=
github.com/smartcontractkit/chainlink-protos/cre/go v0.0.0-20250911124514-5874cc6d62b2/go.mod h1:jUC52kZzEnWF9tddHh85zolKybmLpbQ1oNA4FjOHt1Q=
github.com/smartcontractkit/chainlink-sui v0.0.0-20251104205009-00bd79b81471 h1:EaLuGs7jZ6Vm2iv6rNK3bQ3XN5CRbFd4knjjvaD1zFc=
github.com/smartcontractkit/chainlink-sui v0.0.0-20251104205009-00bd79b81471/go.mod h1:VlyZhVw+a93Sk8rVHOIH6tpiXrMzuWLZrjs1eTIExW8=
github.com/smartcontractkit/chainlink-sui v0.0.0-20251230103558-1e068e723c05 h1:B3OAb2hdaF/nnYfyfJEZ7p4ResnIbb+N58INiq8ySog=
github.com/smartcontractkit/chainlink-sui v0.0.0-20251230103558-1e068e723c05/go.mod h1:u85f5KJMHu5QZOVmIPg0eJ5xHGFS/K8Ly5cns9QNWxU=
github.com/smartcontractkit/chainlink-testing-framework/framework v0.12.1 h1:Ld3OrOQfLubJ+os0/oau2V6RISgsEdBg+Q002zkgXpQ=
github.com/smartcontractkit/chainlink-testing-framework/framework v0.12.1/go.mod h1:r6KXRM1u9ch5KFR2jspkgtyWEC1X+gxPCL8mR63U990=
github.com/smartcontractkit/freeport v0.1.3-0.20250716200817-cb5dfd0e369e h1:Hv9Mww35LrufCdM9wtS9yVi/rEWGI1UnjHbcKKU0nVY=
Expand Down
Loading