face: replace isOnDemand with FacePersistency
Change-Id: Ie6995b2d03bbb90faad158de2b055f72dd9ba73d
Refs: #2989
diff --git a/tests/daemon/mgmt/face-query-status-publisher-common.hpp b/tests/daemon/mgmt/face-query-status-publisher-common.hpp
index a274c52..09582c9 100644
--- a/tests/daemon/mgmt/face-query-status-publisher-common.hpp
+++ b/tests/daemon/mgmt/face-query-status-publisher-common.hpp
@@ -83,12 +83,7 @@
BOOST_CHECK_EQUAL(status.getFaceScope(), ndn::nfd::FACE_SCOPE_NON_LOCAL);
}
- if (reference->isOnDemand()) {
- BOOST_CHECK_EQUAL(status.getFacePersistency(), ndn::nfd::FACE_PERSISTENCY_ON_DEMAND);
- }
- else {
- BOOST_CHECK_EQUAL(status.getFacePersistency(), ndn::nfd::FACE_PERSISTENCY_PERSISTENT);
- }
+ BOOST_CHECK_EQUAL(status.getFacePersistency(), reference->getPersistency());
if (reference->isMultiAccess()) {
BOOST_CHECK_EQUAL(status.getLinkType(), ndn::nfd::LINK_TYPE_MULTI_ACCESS);
diff --git a/tests/daemon/mgmt/face-query-status-publisher.t.cpp b/tests/daemon/mgmt/face-query-status-publisher.t.cpp
index 217a863..09f6804 100644
--- a/tests/daemon/mgmt/face-query-status-publisher.t.cpp
+++ b/tests/daemon/mgmt/face-query-status-publisher.t.cpp
@@ -119,7 +119,7 @@
"/localhost/nfd/FaceStatusPublisherFixture",
filter, m_keyChain);
BOOST_CHECK_EQUAL(faceQueryStatusPublisher.doesMatchFilter(m_dummyFace), false);
- multicastFace->setOnDemand(true);
+ multicastFace->setPersistency(ndn::nfd::FACE_PERSISTENCY_ON_DEMAND);
BOOST_CHECK_EQUAL(faceQueryStatusPublisher.doesMatchFilter(multicastFace), true);
}
diff --git a/tests/daemon/mgmt/face-status-publisher-common.hpp b/tests/daemon/mgmt/face-status-publisher-common.hpp
index 11f4913..d785149 100644
--- a/tests/daemon/mgmt/face-status-publisher-common.hpp
+++ b/tests/daemon/mgmt/face-status-publisher-common.hpp
@@ -142,12 +142,7 @@
BOOST_CHECK_EQUAL(status.getFaceScope(), ndn::nfd::FACE_SCOPE_NON_LOCAL);
}
- if (reference->isOnDemand()) {
- BOOST_CHECK_EQUAL(status.getFacePersistency(), ndn::nfd::FACE_PERSISTENCY_ON_DEMAND);
- }
- else {
- BOOST_CHECK_EQUAL(status.getFacePersistency(), ndn::nfd::FACE_PERSISTENCY_PERSISTENT);
- }
+ BOOST_CHECK_EQUAL(status.getFacePersistency(), reference->getPersistency());
if (reference->isMultiAccess()) {
BOOST_CHECK_EQUAL(status.getLinkType(), ndn::nfd::LINK_TYPE_MULTI_ACCESS);