77 uint randomLimit = 2 +
rani(98);
85 Test& instanceRef = *
this;
90 uint res = std::apply (&LateBindInstance_test::theMember, preparedArgs);
91 CHECK (res < randomLimit);
95 theMember (uint limit)
107 auto& log = Tracker::log;
113 log.
event(
"construct tuple");
114 tuple tup(t1, marker,
Tracker{23}, 55);
116 Test& instanceRef = *
this;
118 log.
event(
"invoke lateBindInstance");
120 log.
event(
"got result");
133 .afterEvent(
"invoke lateBindInstance"));
150 cout <<
"____Tracker-Log_______________\n" 151 << util::join(Tracker::log,
"\n")
152 <<
"\n───╼━━━━━━━━━━━╾──────────────"<<endl;
175 })) ==
"(1,2,↗555,«tuple<int, int>»──(2,3),5.5)"_expect);
EventLog & event(string text)
log some text as event
constexpr auto lateBindInstance(W &instance, TUP &&invocation)
Fix-up the arguments for a member-function invocation, allowing to inject the actual this instance in...
EventMatch & beforeCall(string match)
find a match for some function invocation after the current point of reference
int rani(uint bound=_iBOUND())
EventMatch & arg(ARGS const &...args)
refine filter to additionally require specific arguments
EventMatch verifyEvent(string match) const
start a query to match for some event.
Implementation namespace for support and library code.
Metaprogramming with tuples-of-types and the std::tuple record.
EventMatch verifyCall(string match) const
start a query to match especially a function call
EventMatch ensureNot(string match) const
start a query to ensure the given expression does not match.
Metaprogramming tools for transforming functor types.
A tracking Dummy object for tests.
EventMatch & beforeEvent(string match)
find a match for an "event" after the current point of reference
EventLog & clear()
purge log contents while retaining just the original Header-ID
Simplistic test class runner.
Tiny helper functions and shortcuts to be used everywhere Consider this header to be effectively incl...
unittest helper code: test dummy objects to track instances.
A collection of frequently used helper functions to support unit testing.
std::string dump(std::tuple< TYPES... > const &tuple)
convenience function to dump a given tuple's contents.