Drop unnecessary v2 namespace qualifications
Change-Id: I6358bac6860ca8f2e9cdbd00bb2a929e3af5b2da
diff --git a/tests/unit/security/pib/certificate-container.t.cpp b/tests/unit/security/pib/certificate-container.t.cpp
index b6e9f12..ebb8ca1 100644
--- a/tests/unit/security/pib/certificate-container.t.cpp
+++ b/tests/unit/security/pib/certificate-container.t.cpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
- * Copyright (c) 2013-2019 Regents of the University of California.
+ * Copyright (c) 2013-2021 Regents of the University of California.
*
* This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
*
@@ -75,8 +75,8 @@
BOOST_CHECK_THROW(container.get(id1Key1Cert3Name), Pib::Error);
// check cert
- v2::Certificate cert1 = container.get(id1Key1Cert1.getName());
- v2::Certificate cert2 = container.get(id1Key1Cert2.getName());
+ Certificate cert1 = container.get(id1Key1Cert1.getName());
+ Certificate cert2 = container.get(id1Key1Cert2.getName());
BOOST_CHECK_EQUAL(cert1, id1Key1Cert1);
BOOST_CHECK_EQUAL(cert2, id1Key1Cert2);
@@ -133,8 +133,8 @@
certNames.insert(id1Key1Cert1.getName());
certNames.insert(id1Key1Cert2.getName());
- CertificateContainer::const_iterator it = container.begin();
- std::set<Name>::const_iterator testIt = certNames.begin();
+ auto it = container.begin();
+ auto testIt = certNames.begin();
BOOST_CHECK_EQUAL((*it).getName(), *testIt);
it++;
testIt++;
diff --git a/tests/unit/security/pib/key-container.t.cpp b/tests/unit/security/pib/key-container.t.cpp
index aab7b1c..1a66573 100644
--- a/tests/unit/security/pib/key-container.t.cpp
+++ b/tests/unit/security/pib/key-container.t.cpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
- * Copyright (c) 2013-2019 Regents of the University of California.
+ * Copyright (c) 2013-2021 Regents of the University of California.
*
* This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
*
@@ -76,7 +76,7 @@
// get keys
BOOST_REQUIRE_NO_THROW(container.get(id1Key1Name));
BOOST_REQUIRE_NO_THROW(container.get(id1Key2Name));
- Name id1Key3Name = v2::constructKeyName(id1, name::Component("non-existing-id"));
+ Name id1Key3Name = constructKeyName(id1, name::Component("non-existing-id"));
BOOST_CHECK_THROW(container.get(id1Key3Name), Pib::Error);
// check key
diff --git a/tests/unit/security/pib/key.t.cpp b/tests/unit/security/pib/key.t.cpp
index f5c62fa..544848f 100644
--- a/tests/unit/security/pib/key.t.cpp
+++ b/tests/unit/security/pib/key.t.cpp
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
/*
- * Copyright (c) 2013-2019 Regents of the University of California.
+ * Copyright (c) 2013-2021 Regents of the University of California.
*
* This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
*
@@ -75,20 +75,20 @@
BOOST_AUTO_TEST_CASE(Helpers)
{
- BOOST_CHECK_EQUAL(v2::constructKeyName("/hello", name::Component("world")), "/hello/KEY/world");
+ BOOST_CHECK_EQUAL(constructKeyName("/hello", name::Component("world")), "/hello/KEY/world");
- BOOST_CHECK_EQUAL(v2::isValidKeyName("/hello"), false);
- BOOST_CHECK_EQUAL(v2::isValidKeyName("/hello/KEY"), false);
- BOOST_CHECK_EQUAL(v2::isValidKeyName("/hello/KEY/world"), true);
+ BOOST_CHECK_EQUAL(isValidKeyName("/hello"), false);
+ BOOST_CHECK_EQUAL(isValidKeyName("/hello/KEY"), false);
+ BOOST_CHECK_EQUAL(isValidKeyName("/hello/KEY/world"), true);
- BOOST_CHECK_EQUAL(v2::isValidKeyName("/KEY/hello"), true);
- BOOST_CHECK_EQUAL(v2::isValidKeyName("/hello/world/KEY/!"), true);
+ BOOST_CHECK_EQUAL(isValidKeyName("/KEY/hello"), true);
+ BOOST_CHECK_EQUAL(isValidKeyName("/hello/world/KEY/!"), true);
- BOOST_CHECK_EQUAL(v2::extractIdentityFromKeyName("/KEY/hello"), "/");
- BOOST_CHECK_EQUAL(v2::extractIdentityFromKeyName("/hello/KEY/world"), "/hello");
- BOOST_CHECK_EQUAL(v2::extractIdentityFromKeyName("/hello/world/KEY/!"), "/hello/world");
+ BOOST_CHECK_EQUAL(extractIdentityFromKeyName("/KEY/hello"), "/");
+ BOOST_CHECK_EQUAL(extractIdentityFromKeyName("/hello/KEY/world"), "/hello");
+ BOOST_CHECK_EQUAL(extractIdentityFromKeyName("/hello/world/KEY/!"), "/hello/world");
- BOOST_CHECK_THROW(v2::extractIdentityFromKeyName("/hello"), std::invalid_argument);
+ BOOST_CHECK_THROW(extractIdentityFromKeyName("/hello"), std::invalid_argument);
}
BOOST_AUTO_TEST_SUITE_END() // TestKey