swarm/network: Moved the test configuration inside the test function scope

This commit is contained in:
Attila Gazso 2018-07-31 16:06:02 +02:00
parent c807e0065b
commit 022c7f4d5f

View file

@ -255,6 +255,7 @@ func TestBzzHandshakeSuccess(t *testing.T) {
} }
} }
func TestBzzHandshakeLightNode(t *testing.T) {
var lightNodeTests = []struct { var lightNodeTests = []struct {
name string name string
lightNode bool lightNode bool
@ -263,7 +264,6 @@ var lightNodeTests = []struct {
{"off", false}, {"off", false},
} }
func TestBzzHandshakeLightNode(t *testing.T) {
for _, test := range lightNodeTests { for _, test := range lightNodeTests {
t.Run(test.name, func(t *testing.T) { t.Run(test.name, func(t *testing.T) {
randomAddr := RandomAddr() randomAddr := RandomAddr()