management: Removing deprecated NFD management elements
Change-Id: I64ac0734a3197720ad7eae13b30a90b1ab797106
Refs: #1417
diff --git a/tests/management/test-ndnd-forwarding-entry.cpp b/tests/management/test-ndnd-forwarding-entry.cpp
index c116fd6..1a47780 100644
--- a/tests/management/test-ndnd-forwarding-entry.cpp
+++ b/tests/management/test-ndnd-forwarding-entry.cpp
@@ -17,7 +17,7 @@
0x08, 0x06, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78,
0x8a, 0x01, 0x03};
-BOOST_AUTO_TEST_SUITE(TestForwardingEntry)
+BOOST_AUTO_TEST_SUITE(ManagementTestNdndForwardingEntry)
BOOST_AUTO_TEST_CASE (Encode)
{
diff --git a/tests/management/nfd-control-command.cpp b/tests/management/test-nfd-control-command.cpp
similarity index 99%
rename from tests/management/nfd-control-command.cpp
rename to tests/management/test-nfd-control-command.cpp
index 2a3dec4..36d19e0 100644
--- a/tests/management/nfd-control-command.cpp
+++ b/tests/management/test-nfd-control-command.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdControlCommand)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdControlCommand)
BOOST_AUTO_TEST_CASE(FaceCreate)
{
diff --git a/tests/management/nfd-control-parameters.cpp b/tests/management/test-nfd-control-parameters.cpp
similarity index 97%
rename from tests/management/nfd-control-parameters.cpp
rename to tests/management/test-nfd-control-parameters.cpp
index d8c203b..e0733a3 100644
--- a/tests/management/nfd-control-parameters.cpp
+++ b/tests/management/test-nfd-control-parameters.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdControlParameters)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdControlParameters)
BOOST_AUTO_TEST_CASE(FaceOptions)
{
diff --git a/tests/management/test-nfd-control-response.cpp b/tests/management/test-nfd-control-response.cpp
new file mode 100644
index 0000000..a7add12
--- /dev/null
+++ b/tests/management/test-nfd-control-response.cpp
@@ -0,0 +1,45 @@
+/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
+/**
+ * Copyright (C) 2013 Regents of the University of California.
+ * See COPYING for copyright and distribution information.
+ */
+
+#include "management/nfd-control-response.hpp"
+
+#include "boost-test.hpp"
+
+namespace ndn {
+namespace nfd {
+
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdControlResponse)
+
+const uint8_t TestControlResponse[] = {0x65, 0x17,
+ 0x66, 0x02, 0x01, 0x94, 0x67, 0x11, 0x4e, 0x6f, 0x74,
+ 0x68, 0x69, 0x6e, 0x67, 0x20, 0x6e, 0x6f, 0x74, 0x20,
+ 0x66, 0x6f, 0x75, 0x6e, 0x64};
+
+// ControlResponse
+
+BOOST_AUTO_TEST_CASE(ControlResponseEncode)
+{
+ ControlResponse controlResponse(404, "Nothing not found");
+ const Block &wire = controlResponse.wireEncode();
+
+ BOOST_REQUIRE_EQUAL_COLLECTIONS(TestControlResponse, TestControlResponse+sizeof(TestControlResponse),
+ wire.begin(), wire.end());
+}
+
+BOOST_AUTO_TEST_CASE(ControlResponseDecode)
+{
+ ControlResponse controlResponse;
+
+ BOOST_REQUIRE_NO_THROW(controlResponse.wireDecode(Block(TestControlResponse, sizeof(TestControlResponse))));
+
+ BOOST_REQUIRE_EQUAL(controlResponse.getCode(), 404);
+ BOOST_REQUIRE_EQUAL(controlResponse.getText(), "Nothing not found");
+}
+
+BOOST_AUTO_TEST_SUITE_END()
+
+} // namespace nfd
+} // namespace ndn
diff --git a/tests/management/test-nfd-control.cpp b/tests/management/test-nfd-control.cpp
deleted file mode 100644
index 0aabbe9..0000000
--- a/tests/management/test-nfd-control.cpp
+++ /dev/null
@@ -1,149 +0,0 @@
-/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
-/**
- * Copyright (C) 2013 Regents of the University of California.
- * See COPYING for copyright and distribution information.
- */
-
-#include "management/nfd-control-response.hpp"
-#include "management/nfd-fib-management-options.hpp"
-#include "management/nfd-face-management-options.hpp"
-
-#include "boost-test.hpp"
-
-namespace ndn {
-namespace nfd {
-
-BOOST_AUTO_TEST_SUITE(TestNfdControl)
-
-const uint8_t TestControlResponse[] = {0x65, 0x17,
- 0x66, 0x02, 0x01, 0x94, 0x67, 0x11, 0x4e, 0x6f, 0x74,
- 0x68, 0x69, 0x6e, 0x67, 0x20, 0x6e, 0x6f, 0x74, 0x20,
- 0x66, 0x6f, 0x75, 0x6e, 0x64};
-
-const uint8_t TestFibManagementOptions[] = {
- 0x68, 0x49, 0x07, 0x16, 0x08, 0x09, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x68,
- 0x6f, 0x73, 0x74, 0x08, 0x03, 0x72, 0x65, 0x67, 0x08, 0x04, 0x74, 0x65,
- 0x73, 0x74, 0x69, 0x01, 0x00, 0x6a, 0x01, 0x01, 0x6b, 0x29, 0x07, 0x27,
- 0x08, 0x09, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x68, 0x6f, 0x73, 0x74, 0x08,
- 0x03, 0x6e, 0x66, 0x64, 0x08, 0x08, 0x73, 0x74, 0x72, 0x61, 0x74, 0x65,
- 0x67, 0x79, 0x08, 0x0b, 0x68, 0x65, 0x6c, 0x6c, 0x6f, 0x2d, 0x77, 0x6f,
- 0x72, 0x6c, 0x64
-};
-
-const uint8_t TestFaceManagementOptions[] = {
- 0x68, 0x1e, 0x69, 0x01, 0x0a, 0x72, 0x19, 0x74, 0x63, 0x70, 0x3a, 0x2f,
- 0x2f, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x2e, 0x31, 0x2f, 0x68, 0x65, 0x6c,
- 0x6c, 0x6f, 0x2f, 0x77, 0x6f, 0x72, 0x6c, 0x64
-};
-
-// ControlResponse
-
-BOOST_AUTO_TEST_CASE(ControlResponseEncode)
-{
- ControlResponse controlResponse(404, "Nothing not found");
- const Block &wire = controlResponse.wireEncode();
-
- BOOST_REQUIRE_EQUAL_COLLECTIONS(TestControlResponse, TestControlResponse+sizeof(TestControlResponse),
- wire.begin(), wire.end());
-}
-
-BOOST_AUTO_TEST_CASE(ControlResponseDecode)
-{
- ControlResponse controlResponse;
-
- BOOST_REQUIRE_NO_THROW(controlResponse.wireDecode(Block(TestControlResponse, sizeof(TestControlResponse))));
-
- BOOST_REQUIRE_EQUAL(controlResponse.getCode(), 404);
- BOOST_REQUIRE_EQUAL(controlResponse.getText(), "Nothing not found");
-}
-
-// FibManagementOptions
-
-BOOST_AUTO_TEST_CASE(FibManagementOptionsEncoding)
-{
- Name n("/localhost/reg/test");
- FibManagementOptions opt;
-
- opt.setName(n);
- opt.setFaceId(0);
- opt.setCost(1);
- opt.setStrategy("/localhost/nfd/strategy/hello-world");
-
- const Block& blk = opt.wireEncode();
-
- BOOST_REQUIRE_EQUAL_COLLECTIONS(TestFibManagementOptions,
- TestFibManagementOptions + sizeof(TestFibManagementOptions),
- blk.begin(), blk.end());
-}
-
-BOOST_AUTO_TEST_CASE(FibManagementOptionsFastEncoding)
-{
- Name n("/localhost/reg/test");
- FibManagementOptions opt;
-
- opt.setName(n);
- opt.setFaceId(0);
- opt.setCost(1);
- opt.setStrategy("/localhost/nfd/strategy/hello-world");
-
- EncodingBuffer blk;
-
- BOOST_REQUIRE_NO_THROW(opt.wireEncode(blk));
-
- BOOST_REQUIRE_EQUAL_COLLECTIONS(TestFibManagementOptions,
- TestFibManagementOptions + sizeof(TestFibManagementOptions),
- blk.begin(), blk.end());
-
- EncodingBuffer blk2(4);
-
- BOOST_REQUIRE_NO_THROW(opt.wireEncode(blk2));
-
- BOOST_REQUIRE_EQUAL_COLLECTIONS(TestFibManagementOptions,
- TestFibManagementOptions + sizeof(TestFibManagementOptions),
- blk2.begin(), blk2.end());
-}
-
-BOOST_AUTO_TEST_CASE(FibManagementOptionsDecoding)
-{
- Block blk(TestFibManagementOptions, sizeof(TestFibManagementOptions));
- Name n("/localhost/reg/test");
- FibManagementOptions opt;
-
- BOOST_REQUIRE_NO_THROW(opt.wireDecode(blk));
-
- BOOST_CHECK_EQUAL(opt.getName(), n);
- BOOST_CHECK_EQUAL(opt.getFaceId(), 0);
- BOOST_CHECK_EQUAL(opt.getCost(), 1);
- BOOST_CHECK_EQUAL(opt.getStrategy().toUri(), "/localhost/nfd/strategy/hello-world");
-}
-
-BOOST_AUTO_TEST_CASE(FaceManagementOptionsFastEncoding)
-{
- FaceManagementOptions opt;
-
- opt.setFaceId(10);
- opt.setUri("tcp://1.1.1.1/hello/world");
-
- BOOST_REQUIRE_NO_THROW(opt.wireEncode ());
-
- BOOST_REQUIRE_EQUAL_COLLECTIONS(TestFaceManagementOptions,
- TestFaceManagementOptions + sizeof(TestFaceManagementOptions),
- opt.wireEncode().begin(), opt.wireEncode().end());
-}
-
-BOOST_AUTO_TEST_CASE(FaceManagementOptionsDecoding)
-{
- Block blk(TestFaceManagementOptions, sizeof(TestFaceManagementOptions));
- FaceManagementOptions opt;
-
- BOOST_REQUIRE_NO_THROW(opt.wireDecode(blk));
-
- BOOST_CHECK_EQUAL(opt.getFaceId(), 10);
- BOOST_CHECK_EQUAL(opt.getUri(), "tcp://1.1.1.1/hello/world");
-}
-
-
-BOOST_AUTO_TEST_SUITE_END()
-
-} // namespace nfd
-} // namespace ndn
diff --git a/tests/management/nfd-controller.cpp b/tests/management/test-nfd-controller.cpp
similarity index 98%
rename from tests/management/nfd-controller.cpp
rename to tests/management/test-nfd-controller.cpp
index 37b9cc6..fcb53b2 100644
--- a/tests/management/nfd-controller.cpp
+++ b/tests/management/test-nfd-controller.cpp
@@ -14,7 +14,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdController)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdController)
class CommandFixture
{
diff --git a/tests/management/nfd-face-event-notification.cpp b/tests/management/test-nfd-face-event-notification.cpp
similarity index 98%
rename from tests/management/nfd-face-event-notification.cpp
rename to tests/management/test-nfd-face-event-notification.cpp
index 2ff00cf..230cbd6 100644
--- a/tests/management/nfd-face-event-notification.cpp
+++ b/tests/management/test-nfd-face-event-notification.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdFaceEventNotification)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdFaceEventNotification)
BOOST_AUTO_TEST_CASE(Flags)
{
diff --git a/tests/management/nfd-face-status.cpp b/tests/management/test-nfd-face-status.cpp
similarity index 97%
rename from tests/management/nfd-face-status.cpp
rename to tests/management/test-nfd-face-status.cpp
index 56693dd..fe3457c 100644
--- a/tests/management/nfd-face-status.cpp
+++ b/tests/management/test-nfd-face-status.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdFaceStatus)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdFaceStatus)
BOOST_AUTO_TEST_CASE(Encode)
{
diff --git a/tests/management/test-nfd-fib-entry.cpp b/tests/management/test-nfd-fib-entry.cpp
index ccb26d5..dd191ad 100644
--- a/tests/management/test-nfd-fib-entry.cpp
+++ b/tests/management/test-nfd-fib-entry.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(TestNfdFibEntry)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdFibEntry)
const uint8_t TestNextHopRecord[] =
{
diff --git a/tests/management/nfd-forwarder-status.cpp b/tests/management/test-nfd-forwarder-status.cpp
similarity index 98%
rename from tests/management/nfd-forwarder-status.cpp
rename to tests/management/test-nfd-forwarder-status.cpp
index 2523795..b38f432 100644
--- a/tests/management/nfd-forwarder-status.cpp
+++ b/tests/management/test-nfd-forwarder-status.cpp
@@ -12,7 +12,7 @@
namespace ndn {
namespace nfd {
-BOOST_AUTO_TEST_SUITE(NfdForwarderStatus)
+BOOST_AUTO_TEST_SUITE(ManagementTestNfdForwarderStatus)
BOOST_AUTO_TEST_CASE(Encode)
{
diff --git a/tests/management/test-nrd.cpp b/tests/management/test-nrd.cpp
index 197857d..b287a6b 100644
--- a/tests/management/test-nrd.cpp
+++ b/tests/management/test-nrd.cpp
@@ -11,7 +11,7 @@
namespace ndn {
namespace nrd {
-BOOST_AUTO_TEST_SUITE(TestNrd)
+BOOST_AUTO_TEST_SUITE(ManagementTestNrd)
const uint8_t RealPrefixRegOptions[] = {
0x65, 0x1b, 0x07, 0x16, 0x08, 0x09, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x68, 0x6f, 0x73, 0x74,