aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/swarm/upload_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/swarm/upload_test.go')
-rw-r--r--cmd/swarm/upload_test.go9
1 files changed, 5 insertions, 4 deletions
diff --git a/cmd/swarm/upload_test.go b/cmd/swarm/upload_test.go
index e8161680f..0ac2456a5 100644
--- a/cmd/swarm/upload_test.go
+++ b/cmd/swarm/upload_test.go
@@ -32,6 +32,7 @@ import (
"github.com/ethereum/go-ethereum/log"
swarm "github.com/ethereum/go-ethereum/swarm/api/client"
+ "github.com/ethereum/go-ethereum/swarm/testutil"
"github.com/mattn/go-colorable"
)
@@ -298,8 +299,8 @@ func TestCLISwarmUpDefaultPath(t *testing.T) {
}
func testCLISwarmUpDefaultPath(toEncrypt bool, absDefaultPath bool, t *testing.T) {
- cluster := newTestCluster(t, 1)
- defer cluster.Shutdown()
+ srv := testutil.NewTestSwarmServer(t, serverFunc, nil)
+ defer srv.Close()
tmp, err := ioutil.TempDir("", "swarm-defaultpath-test")
if err != nil {
@@ -323,7 +324,7 @@ func testCLISwarmUpDefaultPath(toEncrypt bool, absDefaultPath bool, t *testing.T
args := []string{
"--bzzapi",
- cluster.Nodes[0].URL,
+ srv.URL,
"--recursive",
"--defaultpath",
defaultPath,
@@ -340,7 +341,7 @@ func testCLISwarmUpDefaultPath(toEncrypt bool, absDefaultPath bool, t *testing.T
up.ExpectExit()
hash := matches[0]
- client := swarm.NewClient(cluster.Nodes[0].URL)
+ client := swarm.NewClient(srv.URL)
m, isEncrypted, err := client.DownloadManifest(hash)
if err != nil {