tests: use Signals from DummyClientFace
refs #2319
Change-Id: I688816fc58828a4f2d8fbad4936cc064816ab123
diff --git a/tests/unit/clients/iterative-query-controller.cpp b/tests/unit/clients/iterative-query-controller.cpp
index 7713a5b..116c6a1 100644
--- a/tests/unit/clients/iterative-query-controller.cpp
+++ b/tests/unit/clients/iterative-query-controller.cpp
@@ -44,10 +44,18 @@
, ndnsim(m_ndnsim.getName(), m_certName, *producerFace, m_session, m_keyChain, validator)
{
run();
- producerFace->onInterest += [&] (const Interest& interest) { consumerFace->receive(interest); };
- consumerFace->onInterest += [&] (const Interest& interest) { producerFace->receive(interest); };
- producerFace->onData += [&] (const Data& data) { consumerFace->receive(data); };
- consumerFace->onData += [&] (const Data& data) { producerFace->receive(data); };
+ producerFace->onSendInterest.connect([this] (const Interest& interest) {
+ io.post([=] { consumerFace->receive(interest); });
+ });
+ consumerFace->onSendInterest.connect([this] (const Interest& interest) {
+ io.post([=] { producerFace->receive(interest); });
+ });
+ producerFace->onSendData.connect([this] (const Data& data) {
+ io.post([=] { consumerFace->receive(data); });
+ });
+ consumerFace->onSendData.connect([this] (const Data& data) {
+ io.post([=] { producerFace->receive(data); });
+ });
}
void