diff --git a/upnp_test.go b/upnp_test.go index 87f4d6e..4d71d14 100644 --- a/upnp_test.go +++ b/upnp_test.go @@ -20,12 +20,12 @@ func TestConcurrentUPNP(t *testing.T) { // now try to concurrently Discover() using 20 threads var wg sync.WaitGroup for i := 0; i < 20; i++ { + wg.Add(1) go func() { - wg.Add(1) defer wg.Done() _, err := Discover() if err != nil { - t.Fatal(err) + t.Error(err) } }() }