diff --git a/tests/daemon/face/lp-reassembler.t.cpp b/tests/daemon/face/lp-reassembler.t.cpp
index 16a3592..073c3db 100644
--- a/tests/daemon/face/lp-reassembler.t.cpp
+++ b/tests/daemon/face/lp-reassembler.t.cpp
@@ -38,7 +38,7 @@
   LpReassemblerFixture()
   {
     reassembler.beforeTimeout.connect(
-      [this] (EndpointId remoteEp, size_t nDroppedFragments) {
+      [this] (const EndpointId& remoteEp, size_t nDroppedFragments) {
         timeoutHistory.emplace_back(remoteEp, nDroppedFragments);
       });
   }
@@ -72,7 +72,7 @@
   bool isComplete = false;
   Block netPacket;
   lp::Packet packet;
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received);
 
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
@@ -93,7 +93,7 @@
   bool isComplete = false;
   Block netPacket;
   lp::Packet packet;
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received);
 
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
@@ -113,7 +113,7 @@
   bool isComplete = false;
   Block netPacket;
   lp::Packet packet;
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received);
 
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
@@ -132,7 +132,7 @@
   bool isComplete = false;
   Block netPacket;
   lp::Packet packet;
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received);
 
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
@@ -172,15 +172,15 @@
   Block netPacket;
   lp::Packet packet;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 1);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 1);
 
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received3);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received3);
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
   BOOST_CHECK_EQUAL_COLLECTIONS(data, data + sizeof(data), netPacket.begin(), netPacket.end());
@@ -215,13 +215,13 @@
   Block netPacket;
   lp::Packet packet;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment(0, received3);
+  std::tie(isComplete, netPacket, packet) = reassembler.receiveFragment({}, received3);
   BOOST_REQUIRE(isComplete);
   BOOST_CHECK(packet.has<lp::NextHopFaceIdField>());
   BOOST_CHECK_EQUAL_COLLECTIONS(data, data + sizeof(data), netPacket.begin(), netPacket.end());
@@ -254,14 +254,14 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, frag2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, frag2);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, frag0);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, frag0);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, frag1);
-  BOOST_REQUIRE(isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, frag1);
+  BOOST_TEST(isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(Duplicate)
@@ -276,11 +276,11 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, frag0);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, frag0);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(1, frag0);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, frag0);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(Timeout)
@@ -301,21 +301,21 @@
   received2.add<lp::FragCountField>(2);
   received2.add<lp::SequenceField>(1001);
 
-  const EndpointId REMOTE_EP = 11028;
+  const EndpointId REMOTE_EP = ethernet::getDefaultMulticastAddress();
   bool isComplete = false;
   std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP, received1);
-  BOOST_REQUIRE(!isComplete);
+  BOOST_TEST(!isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 1);
   BOOST_CHECK(timeoutHistory.empty());
 
   advanceClocks(1_ms, 600);
   BOOST_CHECK_EQUAL(reassembler.size(), 0);
   BOOST_REQUIRE_EQUAL(timeoutHistory.size(), 1);
-  BOOST_CHECK_EQUAL(std::get<0>(timeoutHistory.back()), REMOTE_EP);
+  BOOST_CHECK(std::get<0>(timeoutHistory.back()) == REMOTE_EP);
   BOOST_CHECK_EQUAL(std::get<1>(timeoutHistory.back()), 1);
 
   std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP, received2);
-  BOOST_REQUIRE(!isComplete);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(MissingSequence)
@@ -344,19 +344,19 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received3);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received3);
+  BOOST_TEST(!isComplete);
 
   advanceClocks(1_ms, 600);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(FragCountOverLimit)
@@ -372,8 +372,8 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(MissingFragCount)
@@ -403,14 +403,14 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received3);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received3);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_CASE(OverFragCount)
@@ -444,14 +444,14 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received1);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received1);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received2);
+  BOOST_TEST(!isComplete);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(0, received3);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment({}, received3);
+  BOOST_TEST(!isComplete);
 }
 
 BOOST_AUTO_TEST_SUITE_END() // MultiFragment
@@ -491,20 +491,23 @@
 
   bool isComplete = false;
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(1, frag1_1);
-  BOOST_REQUIRE(!isComplete);
+  const EndpointId REMOTE_EP_1 = ethernet::Address::fromString("11:22:33:45:67:89");
+  const EndpointId REMOTE_EP_2 = ethernet::Address::fromString("11:22:33:ab:cd:ef");
+
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP_1, frag1_1);
+  BOOST_TEST(!isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 1);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(2, frag2_2);
-  BOOST_REQUIRE(!isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP_2, frag2_2);
+  BOOST_TEST(!isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 2);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(1, frag1_2);
-  BOOST_REQUIRE(isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP_1, frag1_2);
+  BOOST_TEST(isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 1);
 
-  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(2, frag2_1);
-  BOOST_REQUIRE(isComplete);
+  std::tie(isComplete, std::ignore, std::ignore) = reassembler.receiveFragment(REMOTE_EP_2, frag2_1);
+  BOOST_TEST(isComplete);
   BOOST_CHECK_EQUAL(reassembler.size(), 0);
 }
 
