fw: invoke FaceTable::remove upon Face::onFail
refs #1358
Change-Id: Ic19a88f0aea5adefbd3179de09f9f4e049922ff8
diff --git a/tests/fw/client-control-strategy.cpp b/tests/fw/client-control-strategy.cpp
index aab5baa..51534a4 100644
--- a/tests/fw/client-control-strategy.cpp
+++ b/tests/fw/client-control-strategy.cpp
@@ -64,7 +64,7 @@
shared_ptr<pit::Entry> pitEntry3 = pit.insert(*interest3).first;
pitEntry3->insertOrUpdateInRecord(face4, *interest3);
- forwarder.removeFace(face3); // face3 is removed and its FaceId becomes invalid
+ face3->close(); // face3 is closed and its FaceId becomes invalid
strategy.m_sendInterestHistory.clear();
strategy.m_rejectPendingInterestHistory.clear();
strategy.afterReceiveInterest(*face4, *interest3, fibEntry, pitEntry3);
diff --git a/tests/fw/face-table.cpp b/tests/fw/face-table.cpp
index 474a756..b07995f 100644
--- a/tests/fw/face-table.cpp
+++ b/tests/fw/face-table.cpp
@@ -32,8 +32,8 @@
BOOST_CHECK_NE(face2->getId(), INVALID_FACEID);
BOOST_CHECK_NE(face1->getId(), face2->getId());
- forwarder.removeFace(face1);
- forwarder.removeFace(face2);
+ face1->close();
+ face2->close();
BOOST_CHECK_EQUAL(face1->getId(), INVALID_FACEID);
BOOST_CHECK_EQUAL(face2->getId(), INVALID_FACEID);
@@ -77,7 +77,7 @@
BOOST_CHECK(hasFace1);
BOOST_CHECK(hasFace2);
- faceTable.remove(face1);
+ face1->close();
BOOST_CHECK_EQUAL(faceTable.size(), 1);
BOOST_CHECK_EQUAL(std::distance(faceTable.begin(), faceTable.end()), faceTable.size());
hasFace1 = hasFace2 = false;