libcruft-util/test/singleton.cpp

14 lines
252 B
C++

#include "singleton.hpp"
#include "tap.hpp"
int main ()
{
util::TAP::logger tap;
auto obj = util::singleton<int>::instantiate (42);
tap.expect_eq (util::singleton<int>::get (), 42, "singleton stores value");
return tap.status ();
}