Main   Namespaces   Classes   Hierarchy   Annotated   Files   Compound   Global   Pages  

HashTest.cpp

Go to the documentation of this file.
00001 //---------------------------------------------------------------------------
00002 /** @file
00003  */
00004 //---------------------------------------------------------------------------
00005 
00006 #include <boost/test/auto_unit_test.hpp>
00007 
00008 #include "Hash.hpp"
00009 
00010 using namespace benzene;
00011 
00012 //---------------------------------------------------------------------------
00013 
00014 namespace {
00015 
00016 BOOST_AUTO_TEST_CASE(Hash_BasicTests)
00017 {
00018     BOOST_CHECK_EQUAL(HashUtil::toString(0),       "0x0000000000000000");
00019     BOOST_CHECK_EQUAL(HashUtil::toString(1),       "0x0000000000000001");
00020     BOOST_CHECK_EQUAL(HashUtil::toString(9),       "0x0000000000000009");
00021     BOOST_CHECK_EQUAL(HashUtil::toString(10),      "0x000000000000000a");
00022     BOOST_CHECK_EQUAL(HashUtil::toString(15),      "0x000000000000000f");
00023     BOOST_CHECK_EQUAL(HashUtil::toString(18),      "0x0000000000000012");
00024     BOOST_CHECK_EQUAL(HashUtil::toString(4736785), "0x0000000000484711");
00025 }
00026 
00027 }
00028 
00029 //---------------------------------------------------------------------------


6 Jan 2011 Doxygen 1.6.3