**breaking** consolidate src/tlv/*lsa* into src/lsa/*lsa*
Lsa de/serialize functions are replaced by wireEncode/Decode.
Update LSA wire formats. Change TLV assignments as required.
Update nlsrc to print using new encoding.
refs: #4787
Change-Id: Ie8d40b7836d51ea5bb444c8db208dc2b3a0d1cec
diff --git a/tests/test-nlsr.cpp b/tests/test-nlsr.cpp
index ab69692..ab5fd15 100644
--- a/tests/test-nlsr.cpp
+++ b/tests/test-nlsr.cpp
@@ -142,7 +142,7 @@
Adjacent neighbor("/ndn/neighborA", ndn::FaceUri(faceUri), 10,
Adjacent::STATUS_INACTIVE, 0, 0);
- BOOST_REQUIRE_EQUAL(conf.getAdjacencyList().insert(neighbor), 0);
+ BOOST_REQUIRE_EQUAL(conf.getAdjacencyList().insert(neighbor), true);
this->advanceClocks(10_ms);
@@ -306,11 +306,11 @@
// Make sure an adjacency LSA was built
ndn::Name key = ndn::Name(conf.getRouterPrefix())
- .append(std::to_string(Lsa::Type::ADJACENCY));
+ .append(boost::lexical_cast<std::string>(Lsa::Type::ADJACENCY));
AdjLsa* lsa = lsdb.findAdjLsa(key);
BOOST_REQUIRE(lsa != nullptr);
- uint32_t lastAdjLsaSeqNo = lsa->getLsSeqNo();
+ uint32_t lastAdjLsaSeqNo = lsa->getSeqNo();
nlsr.m_lsdb.m_sequencingManager.setAdjLsaSeq(lastAdjLsaSeqNo);
this->advanceClocks(1500_ms, 10);
@@ -345,7 +345,7 @@
lsa = lsdb.findAdjLsa(key);
BOOST_REQUIRE(lsa != nullptr);
- BOOST_CHECK_EQUAL(lsa->getLsSeqNo(), lastAdjLsaSeqNo + 1);
+ BOOST_CHECK_EQUAL(lsa->getSeqNo(), lastAdjLsaSeqNo + 1);
this->advanceClocks(15_s, 10);
@@ -381,7 +381,7 @@
receiveHelloData(neighborAName, conf.getRouterPrefix());
this->advanceClocks(1_s, 10);
- ndn::Name lsaKey = ndn::Name(conf.getRouterPrefix()).append(std::to_string(Lsa::Type::ADJACENCY));
+ ndn::Name lsaKey = ndn::Name(conf.getRouterPrefix()).append(boost::lexical_cast<std::string>(Lsa::Type::ADJACENCY));
// Adjacency LSA should be built even though other router is INACTIVE
AdjLsa* lsa = lsdb.findAdjLsa(lsaKey);