tests: respect naming conventions and improve nesting of some test suites
Change-Id: I65af858bc6d10197c6ee11111fa9f7c1faa617ef
Refs: #2497
diff --git a/tests/daemon/face/transport.t.cpp b/tests/daemon/face/transport.t.cpp
index 75bedf8..f1171e5 100644
--- a/tests/daemon/face/transport.t.cpp
+++ b/tests/daemon/face/transport.t.cpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/**
- * Copyright (c) 2014-2015, Regents of the University of California,
+ * Copyright (c) 2014-2016, Regents of the University of California,
* Arizona Board of Regents,
* Colorado State University,
* University Pierre & Marie Curie, Sorbonne University,
@@ -41,15 +41,11 @@
namespace tests {
using namespace nfd::tests;
-namespace ip = boost::asio::ip;
-
-BOOST_AUTO_TEST_SUITE(Face)
-
-using nfd::Face;
+namespace mpl = boost::mpl;
class DummyTransportFixture : public BaseFixture
{
-public:
+protected:
DummyTransportFixture()
: transport(nullptr)
, sentPackets(nullptr)
@@ -68,13 +64,14 @@
this->receivedPackets = &static_cast<DummyReceiveLinkService*>(face->getLinkService())->receivedPackets;
}
-public:
+protected:
unique_ptr<Face> face;
DummyTransport* transport;
std::vector<Transport::Packet>* sentPackets;
std::vector<Transport::Packet>* receivedPackets;
};
+BOOST_AUTO_TEST_SUITE(Face)
BOOST_FIXTURE_TEST_SUITE(TestTransport, DummyTransportFixture)
BOOST_AUTO_TEST_CASE(DummyTransportStaticProperties)
@@ -83,10 +80,6 @@
checkStaticPropertiesInitialized(*transport);
}
-BOOST_AUTO_TEST_SUITE(StateTransition)
-
-namespace mpl = boost::mpl;
-
/** \brief a macro to declare a TransportState as a integral constant
*/
#define TRANSPORT_STATE_C(X) mpl::int_<static_cast<int>(TransportState::X)>
@@ -198,8 +191,6 @@
}
}
-BOOST_AUTO_TEST_SUITE_END() // StateTransition
-
BOOST_AUTO_TEST_CASE(NoExpirationTime)
{
initialize();