Skip to content

Commit

Permalink
fix flaky test TestHandlerStopsWhenContextIsCancelled
Browse files Browse the repository at this point in the history
  • Loading branch information
Peng Yin committed Jul 24, 2018
1 parent fdb8ca0 commit 56bf075
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion agent/acs/handler/acs_handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ import (
"github.com/aws/amazon-ecs-agent/agent/wsclient/mock"
"github.com/aws/aws-sdk-go/aws/credentials"
"github.com/gorilla/websocket"
"github.com/pkg/errors"
"github.com/stretchr/testify/assert"

"github.com/golang/mock/gomock"
Expand Down Expand Up @@ -667,7 +668,7 @@ func TestHandlerStopsWhenContextIsCancelled(t *testing.T) {
mockWsClient.EXPECT().Serve().Return(io.EOF),
mockWsClient.EXPECT().Serve().Do(func() {
cancel()
}).Return(io.EOF),
}).Return(errors.New("InactiveInstanceException")),
)
acsSession := session{
containerInstanceARN: "myArn",
Expand Down

0 comments on commit 56bf075

Please sign in to comment.