MCPcopy Create free account
hub / github.com/cpputest/cpputest / setup

Function setup

tests/CppUTestExt/MemoryReporterPluginTest.cpp:127–140  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

125 UtestShell* test;
126
127 void setup()
128 {
129 previousNewAllocator = getCurrentNewAllocator();
130 result = new TestResult(output);
131 test = new UtestShell("groupname", "testname", "filename", 1);
132 reporter = new MemoryReporterPluginUnderTest;
133
134 mock("formatter").installComparator("TestMemoryAllocator", memLeakAllocatorComparator);
135
136 mock("reporter").disable();
137 const char *cmd_line[] = {"-pmemoryreport=normal"};
138 reporter->parseArguments(1, cmd_line, 0);
139 mock("reporter").enable();
140 }
141 void teardown()
142 {
143 setCurrentNewAllocator(previousNewAllocator);

Callers

nothing calls this directly

Calls 5

getCurrentNewAllocatorFunction · 0.85
installComparatorMethod · 0.45
disableMethod · 0.45
parseArgumentsMethod · 0.45
enableMethod · 0.45

Tested by

no test coverage detected