Commit 9ad55774 authored by Administrator's avatar Administrator
Browse files

Use type_traits functions to do some checks

parent 34cce724
......@@ -161,7 +161,7 @@ public:
private:
friend class boost::serialization::access;
// friend class boost::serialization::access;
static constexpr int kNumAdcBits = 5;
......
......@@ -107,7 +107,7 @@ Set(CbmClusterSources
)
CreateGTestExeAndAddTest(_GTestCbmCluster "${INCLUDE_DIRECTORIES}" "${LINK_DIRECTORIES}"
"${CbmClusterSources}" "${DEPENDENCIES}" "_GTestCbmDigi")
"${CbmClusterSources}" "${DEPENDENCIES}" "_GTestCbmMatch")
Set(CbmHitSources
${CBMDATA_DIR}/CbmHit.cxx
......
......@@ -14,6 +14,7 @@
static const int32_t kTestAddress = CbmStsAddress::GetAddress(5, 6, 1, 8, 0, 0, 1);
#include <type_traits>
TEST(_GTestCbmStsDigi, CheckDefaultConstructor)
{
......@@ -158,4 +159,15 @@ TEST(_GTestCbmStsDigi, CheckSerialization)
boost::archive::binary_iarchive inArchive(s);
inArchive >> read;
compareStsDigiDataMembers(read, kTestAddress, 23, 42, ECbmModuleId::kSts, 987654321);
TEST(_GTestCbmStsDigi, CheckPOD)
{
// #include <iostream>
// std::cout << std::boolalpha;
// std::cout << std::is_pod<A>::value << '\n';
// std::cout << std::is_pod<B>::value << '\n';
// std::cout << std::is_pod<C>::value << '\n';
EXPECT_EQ(true , std::is_default_constructible<CbmStsDigi>::value );
// EXPECT_EQ(true , std::is_trivial<CbmStsDigi>::value );
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment