From 2b8f3630e4a79cfdd8869f9986255b5dc799acdc Mon Sep 17 00:00:00 2001 From: Arjun Dhawan Date: Thu, 24 Oct 2024 11:28:15 +0200 Subject: [PATCH] reword tests --- mock/mock_test.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/mock/mock_test.go b/mock/mock_test.go index 960e745eb..6982bfb5b 100644 --- a/mock/mock_test.go +++ b/mock/mock_test.go @@ -1466,34 +1466,34 @@ func Test_Mock_AssertExpectationsFunctionalOptionsType(t *testing.T) { } -func Test_Mock_AssertExpectationsFunctionalOptionsType_Indirectly(t *testing.T) { +func Test_Mock_AssertExpectationsFunctionalOptionsType_Empty(t *testing.T) { var mockedService = new(TestExampleImplementation) - mockedService.On("TheExampleMethodFunctionalOptions", "test", FunctionalOptions(OpNum(1), OpStr("foo"))).Return(nil).Once() + mockedService.On("TheExampleMethodFunctionalOptions", "test", FunctionalOptions()).Return(nil).Once() tt := new(testing.T) assert.False(t, mockedService.AssertExpectations(tt)) // make the call now - TheExampleMethodFunctionalOptionsIndirect(mockedService) + mockedService.TheExampleMethodFunctionalOptions("test") // now assert expectations assert.True(t, mockedService.AssertExpectations(tt)) } -func Test_Mock_AssertExpectationsFunctionalOptionsType_Empty(t *testing.T) { +func Test_Mock_AssertExpectationsFunctionalOptionsType_Indirectly(t *testing.T) { var mockedService = new(TestExampleImplementation) - mockedService.On("TheExampleMethodFunctionalOptions", "test", FunctionalOptions()).Return(nil).Once() + mockedService.On("TheExampleMethodFunctionalOptions", "test", FunctionalOptions(OpNum(1), OpStr("foo"))).Return(nil).Once() tt := new(testing.T) assert.False(t, mockedService.AssertExpectations(tt)) // make the call now - mockedService.TheExampleMethodFunctionalOptions("test") + TheExampleMethodFunctionalOptionsIndirect(mockedService) // now assert expectations assert.True(t, mockedService.AssertExpectations(tt))