style: clang-tidy: llvm-namespace-comment
diff --git a/tests/local_bindings.h b/tests/local_bindings.h
index b6afb80..22537b1 100644
--- a/tests/local_bindings.h
+++ b/tests/local_bindings.h
@@ -58,7 +58,7 @@
     std::string name_;
     const std::string &name() { return name_; }
 };
-}
+} // namespace pets
 
 struct MixGL { int i; MixGL(int i) : i{i} {} };
 struct MixGL2 { int i; MixGL2(int i) : i{i} {} };
diff --git a/tests/test_constants_and_functions.cpp b/tests/test_constants_and_functions.cpp
index e8ec74b..f607795 100644
--- a/tests/test_constants_and_functions.cpp
+++ b/tests/test_constants_and_functions.cpp
@@ -74,7 +74,7 @@
 #  pragma GCC diagnostic pop
 #endif
 };
-}
+} // namespace test_exc_sp
 
 
 TEST_SUBMODULE(constants_and_functions, m) {
diff --git a/tests/test_custom_type_casters.cpp b/tests/test_custom_type_casters.cpp
index 9485d3c..d565add 100644
--- a/tests/test_custom_type_casters.cpp
+++ b/tests/test_custom_type_casters.cpp
@@ -58,7 +58,8 @@
         return py::none().release();
     }
 };
-}}
+} // namespace detail
+} // namespace pybind11
 
 // test_custom_caster_destruction
 class DestructionTester {
@@ -79,7 +80,8 @@
         return py::bool_(true).release();
     }
 };
-}}
+} // namespace detail
+} // namespace pybind11
 
 TEST_SUBMODULE(custom_type_casters, m) {
     // test_custom_type_casters
diff --git a/tests/test_operator_overloading.cpp b/tests/test_operator_overloading.cpp
index d176c46..d554954 100644
--- a/tests/test_operator_overloading.cpp
+++ b/tests/test_operator_overloading.cpp
@@ -73,7 +73,7 @@
         // Not a good hash function, but easy to test
         size_t operator()(const Vector2 &) { return 4; }
     };
-}
+} // namespace std
 
 // Not a good abs function, but easy to test.
 std::string abs(const Vector2&) {
diff --git a/tests/test_smart_ptr.cpp b/tests/test_smart_ptr.cpp
index bea9069..af7b86e 100644
--- a/tests/test_smart_ptr.cpp
+++ b/tests/test_smart_ptr.cpp
@@ -27,7 +27,8 @@
     struct holder_helper<ref<T>> {
         static const T *get(const ref<T> &p) { return p.get_ptr(); }
     };
-}}
+} // namespace detail
+} // namespace pybind11
 
 // The following is not required anymore for std::shared_ptr, but it should compile without error:
 PYBIND11_DECLARE_HOLDER_TYPE(T, std::shared_ptr<T>);
diff --git a/tests/test_stl.cpp b/tests/test_stl.cpp
index b230717..0590162 100644
--- a/tests/test_stl.cpp
+++ b/tests/test_stl.cpp
@@ -47,7 +47,7 @@
 namespace std {
     template <>
     struct hash<TplCtorClass> { size_t operator()(const TplCtorClass &) const { return 0; } };
-}
+} // namespace std
 
 
 template <template <typename> class OptionalImpl, typename T>
diff --git a/tests/test_tagbased_polymorphic.cpp b/tests/test_tagbased_polymorphic.cpp
index dcc0051..838a168 100644
--- a/tests/test_tagbased_polymorphic.cpp
+++ b/tests/test_tagbased_polymorphic.cpp
@@ -117,7 +117,7 @@
         static const void *get(const itype *src, const std::type_info*& type)
         { type = src ? Animal::type_of_kind(src->kind) : nullptr; return src; }
     };
-}
+} // namespace pybind11
 
 TEST_SUBMODULE(tagbased_polymorphic, m) {
     py::class_<Animal>(m, "Animal")