Skip to content

Commit

Permalink
fix ci
Browse files Browse the repository at this point in the history
Signed-off-by: Denis Tingaikin <denis.tingajkin@xored.com>
  • Loading branch information
denis-tingaikin committed Jan 24, 2022
1 parent 80b5cac commit b8e4189
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/networkservice/chains/nsmgrproxy/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ import (
//
// nsc -> nsmgr1 -> forwarder1 -> nsmgr1 -> nsmgr-proxy1 -> nsmg-proxy2 -> nsmgr2 ->forwarder2 -> nsmgr2 -> nse3
func TestNSMGR_InterdomainUseCase(t *testing.T) {
//t.Cleanup(func() { goleak.VerifyNone(t) })
t.Cleanup(func() { goleak.VerifyNone(t) })

ctx, cancel := context.WithTimeout(context.Background(), time.Hour*5)
defer cancel()
Expand Down
9 changes: 7 additions & 2 deletions pkg/registry/common/connect2/nse_server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,14 +213,16 @@ func TestConnectNSEServer_AllDead_WatchingFind(t *testing.T) {
),
)

errCh := make(chan error, 2)

go func() {
ch := make(chan *registry.NetworkServiceEndpointResponse, 1)
findSrv := streamchannel.NewNetworkServiceEndpointFindServer(clienturlctx.WithClientURL(ctx, url1), ch)
err := s.Find(&registry.NetworkServiceEndpointQuery{
NetworkServiceEndpoint: new(registry.NetworkServiceEndpoint),
Watch: true,
}, findSrv)
require.Error(t, err)
errCh <- err
}()

go func() {
Expand All @@ -230,12 +232,15 @@ func TestConnectNSEServer_AllDead_WatchingFind(t *testing.T) {
NetworkServiceEndpoint: new(registry.NetworkServiceEndpoint),
Watch: true,
}, findSrv)
require.Error(t, err)
errCh <- err
}()

cancel1()
cancel2()

require.Error(t, <-errCh)
require.Error(t, <-errCh)

for err, i := goleak.Find(), 0; err != nil && i < 3; err, i = goleak.Find(), i+1 {
}
}
Expand Down

0 comments on commit b8e4189

Please sign in to comment.