diff options
-rw-r--r-- | .travis.yml | 2 | ||||
-rw-r--r-- | server/server_test.go | 9 |
2 files changed, 6 insertions, 5 deletions
diff --git a/.travis.yml b/.travis.yml index 1f35fa60..7a8a9bf3 100644 --- a/.travis.yml +++ b/.travis.yml @@ -8,7 +8,7 @@ _dep_ensure: &_dep_ensure _unittest: &_unittest <<: *_dep_ensure script: - - go test $(go list ./... | grep -v '/vendor/') + - go test $(go list ./... | grep -v '/vendor/') -timeout 120s - if [ "$(go env GOARCH)" = "amd64" ]; then go test -race github.com/osrg/gobgp/packet/bgp -run ^Test_RaceCondition$; else echo 'skip'; fi - go build -o ./gobgp/gobgp ./gobgp/ - go build -o ./gobgpd/gobgpd ./gobgpd/ diff --git a/server/server_test.go b/server/server_test.go index ff9bfd40..b7a03490 100644 --- a/server/server_test.go +++ b/server/server_test.go @@ -594,7 +594,7 @@ func TestGracefulRestartTimerExpired(t *testing.T) { GracefulRestart: config.GracefulRestart{ Config: config.GracefulRestartConfig{ Enabled: true, - RestartTime: 10, + RestartTime: 1, }, }, } @@ -610,7 +610,7 @@ func TestGracefulRestartTimerExpired(t *testing.T) { Port: -1, }, }) - assert.Nil(err) + require.NoError(t, err) defer s2.Stop() m := &config.Neighbor{ @@ -626,7 +626,7 @@ func TestGracefulRestartTimerExpired(t *testing.T) { GracefulRestart: config.GracefulRestart{ Config: config.GracefulRestartConfig{ Enabled: true, - RestartTime: 10, + RestartTime: 1, }, }, } @@ -658,7 +658,8 @@ func TestGracefulRestartTimerExpired(t *testing.T) { require.NoError(t, err) defer conn.Close() - ctx, cancel := context.WithTimeout(context.Background(), time.Second*3) + // this seems to take around 22 seconds... need to address this whole thing + ctx, cancel := context.WithTimeout(context.Background(), 30*time.Second) defer cancel() // Waiting for Graceful Restart timer expired and moving on to IDLE state. |