42 bool Dummy::_throw_in_ctor =
false;
44 EventLog Tracker::log{
"Instance-Tracker"};
51 static _Fmt fmt{
"sizeof( %s ) %|40t|= %3d"};
52 return fmt % name % siz;
63 static const string alpha{
"aaaabbccddeeeeffgghiiiijjkkllmmnnooooppqqrrssttuuuuvvwwxxyyyyzz0123456789"};
64 static const size_t MAXAL{alpha.size()};
66 string garbage(len,
'\0');
69 garbage[--p] = alpha[
rani (MAXAL)];
82 std::string
const& expected{*
this};
83 bool expectationMatch {actual == expected};
84 if (not expectationMatch)
86 cerr <<
"FAIL___expectation___________" 87 <<
"\nexpect:"<<expected
88 <<
"\nactual:"<<actual
91 return expectationMatch;
static long _local_checksum
to verify ctor/dtor calls
bool verify(std::string const &actual) const
int rani(uint bound=_iBOUND())
Helper to deal with C-MALLOCed memory automatically.
A front-end for using printf-style formatting.
string showSizeof(size_t siz, string name)
for printing sizeof().
Implementation namespace for support and library code.
string randStr(size_t len)
create garbage string of given length
unittest helper code: test dummy objects to track instances.
A collection of frequently used helper functions to support unit testing.
Generating (pseudo) random numbers with controlled seed.