encoding: convert to span
Change-Id: I8bd73284fbd5acc0ff8ad2626af9b4324e9df7a1
diff --git a/tests/unit/link.t.cpp b/tests/unit/link.t.cpp
index 2d7fa9c..fe4b45c 100644
--- a/tests/unit/link.t.cpp
+++ b/tests/unit/link.t.cpp
@@ -77,7 +77,7 @@
BOOST_AUTO_TEST_CASE(Decode)
{
- Link link(Block(GOOD_LINK, sizeof(GOOD_LINK)));
+ Link link(Block{GOOD_LINK});
BOOST_CHECK_EQUAL(link.getName(), Name("/local/ndn/prefix"));
BOOST_TEST(link.getDelegationList() == std::vector<Name>({"/local", "/ndn"}),
boost::test_tools::per_element());
@@ -85,11 +85,11 @@
BOOST_AUTO_TEST_CASE(DecodeBadContentType)
{
- Data linkData(Block(GOOD_LINK, sizeof(GOOD_LINK)));
+ Data linkData(Block{GOOD_LINK});
linkData.setContentType(tlv::ContentType_Key);
Block badLink = linkData.wireEncode();
- BOOST_CHECK_THROW((Link(badLink)), Link::Error);
+ BOOST_CHECK_THROW(Link{badLink}, Link::Error);
Link link;
BOOST_CHECK_THROW(link.wireDecode(badLink), Link::Error);
}