diff --git a/ndn-cxx/name.hpp b/ndn-cxx/name.hpp
index 5f72ef8..2a07f1b 100644
--- a/ndn-cxx/name.hpp
+++ b/ndn-cxx/name.hpp
@@ -44,12 +44,10 @@
 class Name : private boost::totally_ordered<Name>
 {
 public: // nested types
-  using Error = name::Component::Error;
-
   using Component = name::Component;
-  using component_container = std::vector<Component>;
+  using Error = Component::Error;
 
-  // Name appears as a container of name components
+  // Name appears as an ordered sequence of name components
   using value_type             = Component;
   using allocator_type         = void;
   using reference              = Component&;
@@ -60,8 +58,8 @@
   using const_iterator         = const Component*;
   using reverse_iterator       = std::reverse_iterator<iterator>;
   using const_reverse_iterator = std::reverse_iterator<const_iterator>;
-  using difference_type        = component_container::difference_type;
-  using size_type              = component_container::size_type;
+  using difference_type        = std::vector<Component>::difference_type;
+  using size_type              = std::vector<Component>::size_type;
 
 public: // constructors, encoding, decoding
   /**
@@ -344,13 +342,14 @@
     return append(Component(tlv::GenericNameComponent, value));
   }
 
-  /** @brief Append a `NameComponent` of TLV-TYPE @p type, copying the TLV-VALUE from a range.
-   *  @tparam Iterator an @c InputIterator dereferencing to a one-octet value type. More efficient
-   *                   implementation is available when it is a @c RandomAccessIterator.
-   *  @param type      the TLV-TYPE.
-   *  @param first     beginning of the range.
-   *  @param last      past-end of the range.
-   *  @return A reference to this Name, to allow chaining.
+  /**
+   * @brief Append a `NameComponent` of TLV-TYPE @p type, copying the TLV-VALUE from a range.
+   * @tparam Iterator an @c InputIterator dereferencing to a one-octet value type. More efficient
+   *                  implementation is available when it is a @c RandomAccessIterator.
+   * @param type      the TLV-TYPE.
+   * @param first     beginning of the range.
+   * @param last      past-end of the range.
+   * @return A reference to this Name, to allow chaining.
    */
   template<class Iterator>
   Name&
@@ -359,12 +358,13 @@
     return append(Component(type, first, last));
   }
 
-  /** @brief Append a `GenericNameComponent`, copying the TLV-VALUE from a range.
-   *  @tparam Iterator an @c InputIterator dereferencing to a one-octet value type. More efficient
-   *                   implementation is available when it is a @c RandomAccessIterator.
-   *  @param first     beginning of the range.
-   *  @param last      past-end of the range.
-   *  @return A reference to this Name, to allow chaining.
+  /**
+   * @brief Append a `GenericNameComponent`, copying the TLV-VALUE from a range.
+   * @tparam Iterator an @c InputIterator dereferencing to a one-octet value type. More efficient
+   *                  implementation is available when it is a @c RandomAccessIterator.
+   * @param first     beginning of the range.
+   * @param last      past-end of the range.
+   * @return A reference to this Name, to allow chaining.
    */
   template<class Iterator>
   Name&
@@ -373,10 +373,11 @@
     return append(Component(tlv::GenericNameComponent, first, last));
   }
 
-  /** @brief Append a `GenericNameComponent`, copying TLV-VALUE from a null-terminated string.
-   *  @param str a null-terminated string. Bytes from the string are copied as is, and not
-   *             interpreted as URI component.
-   *  @return A reference to this Name, to allow chaining.
+  /**
+   * @brief Append a `GenericNameComponent`, copying the TLV-VALUE from a null-terminated string.
+   * @param str a null-terminated string. Bytes from the string are copied as is, and not
+   *            interpreted as a URI component.
+   * @return A reference to this Name, to allow chaining.
    */
   Name&
   append(const char* str)
@@ -384,9 +385,10 @@
     return append(Component(str));
   }
 
-  /** @brief Append a PartialName.
-   *  @param name the components to append
-   *  @return A reference to this Name, to allow chaining.
+  /**
+   * @brief Append a PartialName.
+   * @param name the components to append
+   * @return A reference to this Name, to allow chaining.
    */
   Name&
   append(const PartialName& name);
@@ -402,15 +404,16 @@
     return append(Component::fromNumber(number));
   }
 
-  /** @brief Append a component with a marked number.
-   *  @param marker 1-octet marker
-   *  @param number the number
+  /**
+   * @brief Append a component with a marked number.
+   * @param marker 1-octet marker
+   * @param number the number
    *
-   *  The component is encoded as a 1-octet marker, followed by a NonNegativeInteger.
+   * The component is encoded as a 1-octet marker, followed by a NonNegativeInteger.
    *
-   *  @return A reference to this Name, to allow chaining.
-   *  @sa NDN Naming Conventions revision 1 (obsolete)
-   *      https://named-data.net/wp-content/uploads/2014/08/ndn-tr-22-ndn-memo-naming-conventions.pdf
+   * @return A reference to this Name, to allow chaining.
+   * @sa NDN Naming Conventions revision 1 (obsolete)
+   *     https://named-data.net/wp-content/uploads/2014/08/ndn-tr-22-ndn-memo-naming-conventions.pdf
    */
   Name&
   appendNumberWithMarker(uint8_t marker, uint64_t number)
@@ -544,17 +547,6 @@
   }
 
   /**
-   * @brief Append a name component.
-   * @note This makes push_back() an alias of append(), giving Name a similar API as `std::vector`.
-   */
-  template<class T>
-  void
-  push_back(const T& component)
-  {
-    append(component);
-  }
-
-  /**
    * @brief Erase the component at the specified index.
    * @param i zero-based index of the component to erase;
    *          if negative, it is interpreted as offset from the end of the name
diff --git a/tests/unit/name.t.cpp b/tests/unit/name.t.cpp
index b105818..a7fdf7a 100644
--- a/tests/unit/name.t.cpp
+++ b/tests/unit/name.t.cpp
@@ -459,7 +459,7 @@
 
 BOOST_AUTO_TEST_CASE(CompareOp)
 {
-  std::vector<Name> names = {
+  const std::vector<Name> names = {
     Name("/"),
     Name("/sha256digest=0000000000000000000000000000000000000000000000000000000000000000"),
     Name("/sha256digest=0000000000000000000000000000000000000000000000000000000000000001"),
@@ -501,8 +501,10 @@
 
   for (size_t i = 0; i < names.size(); ++i) {
     for (size_t j = 0; j < names.size(); ++j) {
-      Name lhs = names[i];
-      Name rhs = names[j];
+      const auto& lhs = names[i];
+      const auto& rhs = names[j];
+      BOOST_TEST_INFO_SCOPE("lhs = " << lhs);
+      BOOST_TEST_INFO_SCOPE("rhs = " << rhs);
       BOOST_CHECK_EQUAL(lhs == rhs, i == j);
       BOOST_CHECK_EQUAL(lhs != rhs, i != j);
       BOOST_CHECK_EQUAL(lhs <  rhs, i <  j);
diff --git a/tests/unit/security/tpm/back-end.t.cpp b/tests/unit/security/tpm/back-end.t.cpp
index d432d73..cb0ec5d 100644
--- a/tests/unit/security/tpm/back-end.t.cpp
+++ b/tests/unit/security/tpm/back-end.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2023 Regents of the University of California.
+ * Copyright (c) 2013-2024 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -343,7 +343,8 @@
   for (int i = 0; i < 100; i++) {
     auto key = tpm.createKey(identity, RsaKeyParams());
     Name keyName = key->getKeyName();
-    BOOST_CHECK(keyNames.insert(keyName).second);
+    BOOST_TEST_INFO_SCOPE("KeyName = " << keyName);
+    BOOST_TEST(keyNames.insert(keyName).second);
   }
 }
 
diff --git a/tests/unit/security/validator-config/checker.t.cpp b/tests/unit/security/validator-config/checker.t.cpp
index 523f1a2..e340b26 100644
--- a/tests/unit/security/validator-config/checker.t.cpp
+++ b/tests/unit/security/validator-config/checker.t.cpp
@@ -40,10 +40,10 @@
 public:
   CheckerFixture()
   {
-    names.push_back("/foo/bar");
-    names.push_back("/foo/bar/bar");
-    names.push_back("/foo");
-    names.push_back("/other/prefix");
+    names.emplace_back("/foo/bar");
+    names.emplace_back("/foo/bar/bar");
+    names.emplace_back("/foo");
+    names.emplace_back("/other/prefix");
   }
 
   static Name
@@ -60,22 +60,6 @@
     return Name(name).append(suffix);
   }
 
-  template<typename PktType, typename C>
-  static void
-  testChecker(C& checker, tlv::SignatureTypeValue sigType, const Name& pktName, const Name& klName, bool expectedOutcome)
-  {
-    BOOST_TEST_INFO_SCOPE("Packet = " << pktName);
-    BOOST_TEST_INFO_SCOPE("KeyLocator = " << klName);
-
-    auto state = PktType::makeState();
-    auto result = checker.check(PktType::getType(), sigType, pktName, klName, *state);
-    BOOST_CHECK_EQUAL(bool(result), expectedOutcome);
-    BOOST_CHECK(boost::logic::indeterminate(state->getOutcome()));
-    if (!result) {
-      BOOST_CHECK_NE(result.getErrorMessage(), "");
-    }
-  }
-
 public:
   std::vector<Name> names;
 };
@@ -308,6 +292,23 @@
   CheckerFixtures
 >;
 
+template<typename PktType, typename C>
+static void
+testChecker(C& checker, tlv::SignatureTypeValue sigType, const Name& pktName, const Name& klName, bool expectedOutcome)
+{
+  BOOST_TEST_INFO_SCOPE("Packet = " << pktName);
+  BOOST_TEST_INFO_SCOPE("SignatureType = " << sigType);
+  BOOST_TEST_INFO_SCOPE("KeyLocator = " << klName);
+
+  auto state = PktType::makeState();
+  auto result = checker.check(PktType::getType(), sigType, pktName, klName, *state);
+  BOOST_TEST(bool(result) == expectedOutcome);
+  BOOST_TEST(boost::logic::indeterminate(state->getOutcome()));
+  if (!result) {
+    BOOST_TEST(!result.getErrorMessage().empty());
+  }
+}
+
 BOOST_FIXTURE_TEST_CASE_TEMPLATE(Checks, T, Tests, boost::mp11::mp_second<T>)
 {
   using PktType = boost::mp11::mp_first<T>;
@@ -321,12 +322,12 @@
       bool expectedOutcome = this->outcomes[i][j];
 
       auto klName = this->makeKeyLocatorKeyName(this->names[j]);
-      this->template testChecker<PktType>(this->checker, tlv::SignatureSha256WithRsa, pktName, klName, expectedOutcome);
-      this->template testChecker<PktType>(this->checker, tlv::SignatureSha256WithEcdsa, pktName, klName, false);
+      testChecker<PktType>(this->checker, tlv::SignatureSha256WithRsa, pktName, klName, expectedOutcome);
+      testChecker<PktType>(this->checker, tlv::SignatureSha256WithEcdsa, pktName, klName, false);
 
       klName = this->makeKeyLocatorCertName(this->names[j]);
-      this->template testChecker<PktType>(this->checker, tlv::SignatureSha256WithRsa, pktName, klName, expectedOutcome);
-      this->template testChecker<PktType>(this->checker, tlv::SignatureSha256WithEcdsa, pktName, klName, false);
+      testChecker<PktType>(this->checker, tlv::SignatureSha256WithRsa, pktName, klName, expectedOutcome);
+      testChecker<PktType>(this->checker, tlv::SignatureSha256WithEcdsa, pktName, klName, false);
     }
   }
 }
diff --git a/tests/unit/util/sha256.t.cpp b/tests/unit/util/sha256.t.cpp
index 4a31ac7..55eaa10 100644
--- a/tests/unit/util/sha256.t.cpp
+++ b/tests/unit/util/sha256.t.cpp
@@ -1,6 +1,6 @@
 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
 /*
- * Copyright (c) 2013-2023 Regents of the University of California.
+ * Copyright (c) 2013-2024 Regents of the University of California.
  *
  * This file is part of ndn-cxx library (NDN C++ library with eXperimental eXtensions).
  *
@@ -25,6 +25,8 @@
 #include "tests/boost-test.hpp"
 
 #include <boost/endian/conversion.hpp>
+
+#include <array>
 #include <sstream>
 
 namespace ndn::tests {
@@ -114,12 +116,12 @@
 
 BOOST_AUTO_TEST_CASE(InsertionOperatorUnsignedInt)
 {
-  const uint64_t input[] = {1, 2, 3, 4};
+  const std::array input{1, 2, 3, 4};
   auto expected = fromHex("7236c00c170036c6de133a878210ddd58567aa1d0619a0f70f69e38ae6f916e9");
 
   Sha256 statefulSha256;
-  for (size_t i = 0; i < sizeof(input) / sizeof(uint64_t); ++i) {
-    statefulSha256 << boost::endian::native_to_big(input[i]);
+  for (auto i : input) {
+    statefulSha256 << boost::endian::native_to_big(static_cast<uint64_t>(i));
   }
   ConstBufferPtr digest = statefulSha256.computeDigest();
 
