From f4d9d698792fd8ec711b9bf2cfc6405a098a7874 Mon Sep 17 00:00:00 2001 From: Kirill Date: Thu, 17 Oct 2024 15:56:02 +0400 Subject: [PATCH] Add missing gomock.Controller.Finish() calls in plugin tests (#2225) --- plugin/service_test.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugin/service_test.go b/plugin/service_test.go index 786cfc6a6..84e1e6ae9 100644 --- a/plugin/service_test.go +++ b/plugin/service_test.go @@ -14,6 +14,7 @@ import ( func TestService(t *testing.T) { t.Run("shutdown ok", func(t *testing.T) { ctrl := gomock.NewController(t) + defer ctrl.Finish() p := mocks.NewMockJunoPlugin(ctrl) p.EXPECT().Shutdown().Return(nil) @@ -28,6 +29,7 @@ func TestService(t *testing.T) { }) t.Run("shutdown with error", func(t *testing.T) { ctrl := gomock.NewController(t) + defer ctrl.Finish() shutdownErr := errors.New("error during shutdown")