Skip to content

Commit e912650

Browse files
committed
Improved unit test for MockSupport::setMaxCallLogSize().
1 parent faf07f9 commit e912650

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/CppUTestExt/MockSupportTest.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,12 +148,14 @@ TEST(MockSupportTest, tracing)
148148

149149
TEST(MockSupportTest, setMaxCallLogSize)
150150
{
151+
mock("bii").setMaxCallLogSize(10);
151152
mock().setMaxCallLogSize(2);
152153
mock("foo").setMaxCallLogSize(3);
153154

154155
mock().expectAnyCalls("boo");
155156
mock("foo").expectAnyCalls("baa");
156157
mock("bar").expectAnyCalls("buu");
158+
mock("bii").expectAnyCalls("bee");
157159

158160
mock().actualCall("boo");
159161
mock().actualCall("boo");
@@ -170,10 +172,15 @@ TEST(MockSupportTest, setMaxCallLogSize)
170172
mock("bar").actualCall("buu");
171173
mock("bar").actualCall("buu");
172174
mock("bar").actualCall("buu");
175+
mock("bii").actualCall("bee");
176+
mock("bii").actualCall("bee");
177+
mock("bii").actualCall("bee");
178+
mock("bii").actualCall("bee");
173179

174180
LONGS_EQUAL(2, mock().getActualCalls().size())
175181
LONGS_EQUAL(3, mock("foo").getActualCalls().size())
176182
LONGS_EQUAL(2, mock("bar").getActualCalls().size())
183+
LONGS_EQUAL(2, mock("bii").getActualCalls().size())
177184
}
178185

179186
TEST(MockSupportTest, tracingWorksHierarchically)

0 commit comments

Comments
 (0)