// $Id$
//
-// Copyright (C) 2006
+// Copyright (C) 2006
// Fraunhofer Institut fuer offene Kommunikationssysteme (FOKUS)
// Kompetenzzentrum fuer Satelitenkommunikation (SatCom)
// Stefan Bund <stefan.bund@fokus.fraunhofer.de>
{
// We have a Problem here .. packet sockets are only allowed for root
if (getuid() != 0) {
- BOOST_WARN_MESSAGE(false, "Cannot test satcom::lib::PacketSocketHandle as non-root user");
+ BOOST_WARN_MESSAGE(false, "Cannot test senf::PacketSocketHandle as non-root user");
return;
}
{
- satcom::lib::PacketSocketHandle sock;
-
- BOOST_CHECK_NO_THROW( sock.bind(satcom::lib::LLSocketAddress("lo")) );
- satcom::lib::LLSocketAddress a;
+ senf::PacketSocketHandle sock;
+
+ BOOST_CHECK_NO_THROW( sock.bind(senf::LLSocketAddress("eth0")) );
+ senf::LLSocketAddress a;
BOOST_CHECK_NO_THROW( sock.local(a) );
- BOOST_CHECK_EQUAL( a.interface(), "lo" );
+ BOOST_CHECK_EQUAL( a.interface(), "eth0" );
// How am I supposed to test read and write .. grmpf ..
-
- // TODO: There are some failures here ... need to investigate
- /*
- BOOST_CHECK_NO_THROW( sock.protocol().promisc(
- "lo",satcom::lib::PacketProtocol::Promiscuous) );
- BOOST_CHECK_NO_THROW( sock.protocol().promisc(
- "lo",satcom::lib::PacketProtocol::AllMulticast) );
- BOOST_CHECK_NO_THROW( sock.protocol().promisc(
- "lo",satcom::lib::PacketProtocol::None) );
- */
-
+
BOOST_CHECK_NO_THROW( sock.protocol().mcAdd(
- "lo",satcom::lib::llAddress("01-02-03-04-05-06")) );
+ "eth0",senf::llAddress("01-02-03-04-05-06")) );
BOOST_CHECK_NO_THROW( sock.protocol().mcDrop(
- "lo",satcom::lib::llAddress("01-02-03-04-05-06")) );
+ "eth0",senf::llAddress("01-02-03-04-05-06")) );
BOOST_CHECK_NO_THROW( sock.protocol().available() );
BOOST_CHECK( ! sock.eof() );
\f
// Local Variables:
// mode: c++
-// c-file-style: "satcom"
+// fill-column: 100
+// c-file-style: "senf"
+// indent-tabs-mode: nil
+// ispell-local-dictionary: "american"
// End: