libcruft-util/test/concepts.cpp

15 lines
463 B
C++
Raw Normal View History

2020-02-18 11:23:21 +11:00
#include <cruft/util/tap.hpp>
#include <cruft/util/concepts.hpp>
int main ()
{
cruft::TAP::logger tap;
tap.expect (cruft::concepts::container<std::vector<int>>, "vector is a container");
tap.expect (!cruft::concepts::container<int>, "int is not a container");
tap.expect (cruft::concepts::tuple<std::tuple<>>, "tuple<> is a tuple");
tap.expect (cruft::concepts::tuple<std::tuple<int>>, "tuple<int> is a tuple");
2020-02-18 11:23:21 +11:00
return tap.status ();
}