From e9c4be7e0a8f690c210ec4ae21536bebafeabe60 Mon Sep 17 00:00:00 2001 From: Adnan Khan Date: Fri, 21 Dec 2018 12:02:04 -0800 Subject: [PATCH] dockerclient: set mock expectations count --- agent/dockerclient/dockerapi/docker_client_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/agent/dockerclient/dockerapi/docker_client_test.go b/agent/dockerclient/dockerapi/docker_client_test.go index 3bf2cf86aaa..a095f458a18 100644 --- a/agent/dockerclient/dockerapi/docker_client_test.go +++ b/agent/dockerclient/dockerapi/docker_client_test.go @@ -736,7 +736,7 @@ func TestContainerEventsStreamError(t *testing.T) { eventsChan := make(chan events.Message, dockerEventBufferSize) errChan := make(chan error) - mockDockerSDK.EXPECT().Events(gomock.Any(), gomock.Any()).Return(eventsChan, errChan).Times(2) + mockDockerSDK.EXPECT().Events(gomock.Any(), gomock.Any()).Return(eventsChan, errChan).MinTimes(1) dockerEvents, err := client.ContainerEvents(context.TODO()) require.NoError(t, err, "Could not get container events")