From eb618f23b19c71f4a575810062700314e26d3bd2 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Fri, 21 May 2021 18:17:13 +0100 Subject: Add test file for odds and ends --- test/Jamfile.jam | 1 + test/test-misc.cpp | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 test/test-misc.cpp diff --git a/test/Jamfile.jam b/test/Jamfile.jam index e6a833a..3c479b9 100644 --- a/test/Jamfile.jam +++ b/test/Jamfile.jam @@ -9,3 +9,4 @@ project : requirements run test-rawDataReader.cpp ; run test-bitset.cpp ; run test-streams.cpp ; +run test-misc.cpp ; diff --git a/test/test-misc.cpp b/test/test-misc.cpp new file mode 100644 index 0000000..cc9154a --- /dev/null +++ b/test/test-misc.cpp @@ -0,0 +1,12 @@ +#define BOOST_TEST_MODULE BitSet +#include + +#include +#include + +BOOST_AUTO_TEST_CASE(verify) +{ + BOOST_CHECK_NO_THROW(MyGrate::verify(true, "no throw")); + BOOST_CHECK_THROW(MyGrate::verify(false, "throw re"), std::runtime_error); + BOOST_CHECK_THROW(MyGrate::verify(false, "throw le"), std::logic_error); +} -- cgit v1.2.3