fw: reorder function params to make the strategy API more uniform
Also add a non-const overload of Face::getCounters to avoid const_cast
Refs: #5173
Change-Id: Iff0bfbdedb90e68a373090cf3f247d9a7501f58d
diff --git a/tests/daemon/fw/strategy-scope-control.t.cpp b/tests/daemon/fw/strategy-scope-control.t.cpp
index 5c6c552..6fd052e 100644
--- a/tests/daemon/fw/strategy-scope-control.t.cpp
+++ b/tests/daemon/fw/strategy-scope-control.t.cpp
@@ -128,7 +128,7 @@
pitEntry->insertOrUpdateInRecord(*this->localFace3, *interest);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveInterest(FaceEndpoint(*this->localFace3, 0), *interest, pitEntry); },
+ [&] { this->strategy.afterReceiveInterest(*interest, FaceEndpoint(*this->localFace3, 0), pitEntry); },
this->limitedIo));
BOOST_CHECK_EQUAL(this->strategy.sendInterestHistory.size(), 1);
@@ -147,7 +147,7 @@
pitEntry->insertOrUpdateInRecord(*this->localFace3, *interest);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveInterest(FaceEndpoint(*this->localFace3, 0), *interest, pitEntry); },
+ [&] { this->strategy.afterReceiveInterest(*interest, FaceEndpoint(*this->localFace3, 0), pitEntry); },
this->limitedIo, T::willRejectPitEntry() + T::willSendNackNoRoute()));
BOOST_CHECK_EQUAL(this->strategy.sendInterestHistory.size(), 0);
@@ -170,7 +170,7 @@
pitEntry->insertOrUpdateInRecord(*this->localFace3, *interest);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveInterest(FaceEndpoint(*this->localFace3, 0), *interest, pitEntry); },
+ [&] { this->strategy.afterReceiveInterest(*interest, FaceEndpoint(*this->localFace3, 0), pitEntry); },
this->limitedIo));
BOOST_REQUIRE_EQUAL(this->strategy.sendInterestHistory.size(), 1);
@@ -190,7 +190,7 @@
pitEntry->insertOrUpdateInRecord(*this->nonLocalFace1, *interest);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveInterest(FaceEndpoint(*this->nonLocalFace1, 0), *interest, pitEntry); },
+ [&] { this->strategy.afterReceiveInterest(*interest, FaceEndpoint(*this->nonLocalFace1, 0), pitEntry); },
this->limitedIo, T::willRejectPitEntry() + T::willSendNackNoRoute()));
BOOST_CHECK_EQUAL(this->strategy.sendInterestHistory.size(), 0);
@@ -213,7 +213,7 @@
pitEntry->insertOrUpdateInRecord(*this->nonLocalFace1, *interest);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveInterest(FaceEndpoint(*this->nonLocalFace1, 0), *interest, pitEntry); },
+ [&] { this->strategy.afterReceiveInterest(*interest, FaceEndpoint(*this->nonLocalFace1, 0), pitEntry); },
this->limitedIo));
BOOST_REQUIRE_EQUAL(this->strategy.sendInterestHistory.size(), 1);
@@ -236,7 +236,7 @@
pitEntry->insertOrUpdateOutRecord(*this->localFace4, *interest)->setIncomingNack(nack);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveNack(FaceEndpoint(*this->localFace4, 0), nack, pitEntry); },
+ [&] { this->strategy.afterReceiveNack(nack, FaceEndpoint(*this->localFace4, 0), pitEntry); },
this->limitedIo, T::canProcessNack()));
BOOST_CHECK_EQUAL(this->strategy.sendInterestHistory.size(), 0);
@@ -261,7 +261,7 @@
pitEntry->insertOrUpdateOutRecord(*this->localFace4, *interest)->setIncomingNack(nack);
BOOST_REQUIRE(this->strategy.waitForAction(
- [&] { this->strategy.afterReceiveNack(FaceEndpoint(*this->localFace4, 0), nack, pitEntry); },
+ [&] { this->strategy.afterReceiveNack(nack, FaceEndpoint(*this->localFace4, 0), pitEntry); },
this->limitedIo, T::canProcessNack()));
BOOST_CHECK_EQUAL(this->strategy.sendInterestHistory.size(), 0);