From e8345a19ac729d569171ebcb9a6833704241b85b Mon Sep 17 00:00:00 2001 From: Maru Newby Date: Tue, 28 Nov 2023 14:04:16 +0100 Subject: [PATCH] Fix compilation errors --- tests/fixture/e2e/helpers.go | 5 +++-- tests/fixture/tmpnet/local/network.go | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/fixture/e2e/helpers.go b/tests/fixture/e2e/helpers.go index 9930730c1a08..ef4036e07228 100644 --- a/tests/fixture/e2e/helpers.go +++ b/tests/fixture/e2e/helpers.go @@ -24,6 +24,7 @@ import ( "github.com/ava-labs/avalanchego/tests" "github.com/ava-labs/avalanchego/tests/fixture/tmpnet" "github.com/ava-labs/avalanchego/tests/fixture/tmpnet/local" + "github.com/ava-labs/avalanchego/utils/set" "github.com/ava-labs/avalanchego/vms/platformvm/txs/executor" "github.com/ava-labs/avalanchego/vms/secp256k1fx" "github.com/ava-labs/avalanchego/wallet/subnet/primary" @@ -67,7 +68,7 @@ func NewWallet(keychain *secp256k1fx.Keychain, nodeURI tmpnet.NodeURI) primary.W } // Create a new wallet for the provided keychain against the specified node URI. -func NewWalletWithTxIDs(keychain *secp256k1fx.Keychain, nodeURI testnet.NodeURI, txIDs ...ids.ID) primary.Wallet { +func NewWalletWithTxIDs(keychain *secp256k1fx.Keychain, nodeURI tmpnet.NodeURI, txIDs ...ids.ID) primary.Wallet { tests.Outf("{{blue}} initializing a new wallet for node %s with URI: %s {{/}}\n", nodeURI.NodeID, nodeURI.URI) baseWallet, err := primary.MakeWallet(DefaultContext(), &primary.WalletConfig{ URI: nodeURI.URI, @@ -258,7 +259,7 @@ func StartLocalNetwork(avalancheGoExecPath string, networkDir string) *local.Loc return network } -func RegisterNodeforCleanup(node testnet.Node) { +func RegisterNodeforCleanup(node tmpnet.Node) { ginkgo.DeferCleanup(func() { tests.Outf("shutting down ephemeral node %q\n", node.GetID()) ctx, cancel := context.WithTimeout(context.Background(), DefaultTimeout) diff --git a/tests/fixture/tmpnet/local/network.go b/tests/fixture/tmpnet/local/network.go index be9e0bc7d2af..5e4fc55c3234 100644 --- a/tests/fixture/tmpnet/local/network.go +++ b/tests/fixture/tmpnet/local/network.go @@ -15,6 +15,7 @@ import ( "strconv" "time" + "github.com/ava-labs/avalanchego/utils/set" "github.com/ava-labs/avalanchego/config" "github.com/ava-labs/avalanchego/genesis" "github.com/ava-labs/avalanchego/ids" @@ -22,7 +23,6 @@ import ( "github.com/ava-labs/avalanchego/utils/constants" "github.com/ava-labs/avalanchego/utils/crypto/secp256k1" "github.com/ava-labs/avalanchego/utils/perms" - "github.com/ava-labs/avalanchego/utils/set" ) const ( @@ -450,7 +450,7 @@ func (ln *LocalNetwork) GetURIs() []tmpnet.NodeURI { // Stop all nodes in the network. func (ln *LocalNetwork) Stop() error { // Assume the nodes are loaded and the pids are current - allNodes := []testnet.Node{} + allNodes := []tmpnet.Node{} for _, node := range ln.Nodes { allNodes = append(allNodes, node) }