diff --git a/go/registry/tests/tester.go b/go/registry/tests/tester.go index 96f76b2496f..8815200cad1 100644 --- a/go/registry/tests/tester.go +++ b/go/registry/tests/tester.go @@ -602,21 +602,18 @@ func (ent *TestEntity) NewTestNodes(nCompute int, nStorage int, runtimes []*node } nod.Entity = ent - var thisNodeRuntimes []*node.Runtime var role node.RolesMask if i < nCompute { role = node.RoleComputeWorker - thisNodeRuntimes = runtimes } else { role = node.RoleStorageWorker - thisNodeRuntimes = nil } nod.Node = &node.Node{ ID: nod.Signer.Public(), EntityID: ent.Entity.ID, Expiration: uint64(expiration), - Runtimes: thisNodeRuntimes, + Runtimes: runtimes, Roles: role, } addr := node.Address{ @@ -771,7 +768,7 @@ func (ent *TestEntity) NewTestNodes(nCompute int, nStorage int, runtimes []*node ID: nod.Signer.Public(), EntityID: ent.Entity.ID, Expiration: uint64(expiration), - Runtimes: thisNodeRuntimes, + Runtimes: runtimes, Roles: role, } addr = node.Address{ @@ -792,7 +789,7 @@ func (ent *TestEntity) NewTestNodes(nCompute int, nStorage int, runtimes []*node // Add invalid Re-Registration with changed Runtimes field. testRuntimeSigner := memorySigner.NewTestSigner("invalid-registration-runtime-seed") - newRuntimes := append([]*node.Runtime(nil), thisNodeRuntimes...) + newRuntimes := append([]*node.Runtime(nil), runtimes...) newRuntimes = append(newRuntimes, &node.Runtime{ID: publicKeyToNamespace(testRuntimeSigner.Public())}) newNode := &node.Node{ ID: nod.Signer.Public(),