mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
swarm/pss: minor refactoring
This commit is contained in:
parent
a198ac7a08
commit
2de3d0934b
1 changed files with 3 additions and 2 deletions
|
|
@ -213,13 +213,14 @@ func testProxNetwork(t *testing.T) {
|
|||
services := newProxServices(tstdata, true, handlerContextFuncs, tstdata.kademlias)
|
||||
tstdata.sim = simulation.New(services)
|
||||
defer tstdata.sim.Close()
|
||||
err := tstdata.sim.UploadSnapshot(fmt.Sprintf("testdata/snapshot_%d.json", nodeCount))
|
||||
filename := fmt.Sprintf("testdata/snapshot_%d.json", nodeCount)
|
||||
err := tstdata.sim.UploadSnapshot(filename)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
ctx, cancel := context.WithTimeout(context.Background(), time.Second*120)
|
||||
defer cancel()
|
||||
snap, err := simulation.ReadSnapshot(fmt.Sprintf("testdata/snapshot_%d.json", nodeCount))
|
||||
snap, err := simulation.ReadSnapshot(filename)
|
||||
if err != nil {
|
||||
t.Fatalf("failed to read snapshot: %s", err)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue