X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=senf%2FPackets%2FAuxParser.test.cc;h=90b0b7e0fc6c2ed79d14d794dd801690c6c23659;hb=7ee689fe38d66aa3a0004d55e8708750d35adc0b;hp=ff7aaa2b966868a3ee5f96fe142caf80ef803a03;hpb=601d1f509f5bb24df167a4dd5a20da67a0af9af8;p=senf.git diff --git a/senf/Packets/AuxParser.test.cc b/senf/Packets/AuxParser.test.cc index ff7aaa2..90b0b7e 100644 --- a/senf/Packets/AuxParser.test.cc +++ b/senf/Packets/AuxParser.test.cc @@ -1,6 +1,6 @@ // $Id$ // -// Copyright (C) 2009 +// Copyright (C) 2009 // Fraunhofer Institute for Open Communication Systems (FOKUS) // Competence Center NETwork research (NET), St. Augustin, GERMANY // Stefan Bund @@ -29,15 +29,15 @@ // Custom includes #include "Packets.hh" -#include "../Utils/auto_unit_test.hh" +#include #include #define prefix_ -///////////////////////////////cc.p//////////////////////////////////////// +//-///////////////////////////////////////////////////////////////////////////////////////////////// // The other aux policies are tested with the corresponding container classes -BOOST_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy) +SENF_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy) { unsigned char data[] = { 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25 }; @@ -74,7 +74,7 @@ BOOST_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy) } } -BOOST_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy_transformed) +SENF_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy_transformed) { unsigned char data[] = { 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25 }; @@ -89,7 +89,7 @@ BOOST_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy_transformed) { UInt16VectorParser v (p.data().begin(), &p.data()); - + BOOST_REQUIRE_EQUAL( v.size(), p.data().size()/2 ); BOOST_CHECK_EQUAL( v[0], 0x1011u ); BOOST_CHECK_EQUAL( v[1], 0x1213u ); @@ -111,15 +111,15 @@ BOOST_AUTO_UNIT_TEST(vectorPacketSizeAuxPolicy_transformed) w.erase(w.begin()+3, w.begin()+5); BOOST_CHECK_EQUAL( w.size(), p.data().size()/2 ); - senf::UInt16Parser::value_type data2[] = + senf::UInt16Parser::value_type data2[] = { 0x1011u, 0x0000u, 0x1213u, 0x2223u, 0x2425u }; - BOOST_CHECK_EQUAL_COLLECTIONS( w.begin(), w.end(), + BOOST_CHECK_EQUAL_COLLECTIONS( w.begin(), w.end(), data2, data2+sizeof(data2)/sizeof(data2[0]) ); } } -BOOST_AUTO_UNIT_TEST(listPacketSizeAuxPolicy) +SENF_AUTO_UNIT_TEST(listPacketSizeAuxPolicy) { unsigned char data[] = { 0x10, 0x11, 0x12, 0x13, 0x14, 0x15, 0x20, 0x21, 0x22, 0x23, 0x24, 0x25 }; @@ -154,15 +154,15 @@ BOOST_AUTO_UNIT_TEST(listPacketSizeAuxPolicy) w.erase(boost::next(w.begin(),3), boost::next(w.begin(),5)); BOOST_CHECK_EQUAL( w.size(), p.data().size()/2 ); - senf::UInt16Parser::value_type data2[] = + senf::UInt16Parser::value_type data2[] = { 0x1011u, 0x0000u, 0x1213u, 0x2223u, 0x2425u }; - BOOST_CHECK_EQUAL_COLLECTIONS( w.begin(), w.end(), + BOOST_CHECK_EQUAL_COLLECTIONS( w.begin(), w.end(), data2, data2+sizeof(data2)/sizeof(data2[0]) ); } } -///////////////////////////////cc.e//////////////////////////////////////// +//-///////////////////////////////////////////////////////////////////////////////////////////////// #undef prefix_