28 #ifndef D_MemoryReportFormatter_h 29 #define D_MemoryReportFormatter_h 34 class MemoryReportFormatter
37 virtual ~MemoryReportFormatter(){}
39 virtual void report_testgroup_start(TestResult* result, UtestShell& test)=0;
40 virtual void report_testgroup_end(TestResult* result, UtestShell& test)=0;
42 virtual void report_test_start(TestResult* result, UtestShell& test)=0;
43 virtual void report_test_end(TestResult* result, UtestShell& test)=0;
45 virtual void report_alloc_memory(TestResult* result, TestMemoryAllocator* allocator,
size_t size,
char* memory,
const char* file,
int line)=0;
46 virtual void report_free_memory(TestResult* result, TestMemoryAllocator* allocator,
char* memory,
const char* file,
int line)=0;
49 class NormalMemoryReportFormatter :
public MemoryReportFormatter
52 NormalMemoryReportFormatter();
53 virtual ~NormalMemoryReportFormatter();
55 virtual void report_testgroup_start(TestResult* , UtestShell& ) _override;
56 virtual void report_testgroup_end(TestResult* , UtestShell& ) _override {}
58 virtual void report_test_start(TestResult* result, UtestShell& test) _override;
59 virtual void report_test_end(TestResult* result, UtestShell& test) _override;
61 virtual void report_alloc_memory(TestResult* result, TestMemoryAllocator* allocator,
size_t size,
char* memory,
const char* file,
int line) _override;
62 virtual void report_free_memory(TestResult* result, TestMemoryAllocator* allocator,
char* memory,
const char* file,
int line) _override;