From 895205729585166f19f16c371ec827c76497b679 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Fri, 9 Oct 2026 14:41:39 +0200 Subject: [PATCH] Use the with_object_t alias for the custom object key test types Signed-off-by: Niels Lohmann --- tests/src/custom_object_key_type.hpp | 2 +- tests/src/unit-custom-object-key-type.cpp | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/src/custom_object_key_type.hpp b/tests/src/custom_object_key_type.hpp index fa23736d4..ebf499844 100644 --- a/tests/src/custom_object_key_type.hpp +++ b/tests/src/custom_object_key_type.hpp @@ -71,5 +71,5 @@ class object using base_type::base_type; }; -using json = nlohmann::basic_json; +using json = nlohmann::json::with_object_t; } // namespace custom_object_key_test diff --git a/tests/src/unit-custom-object-key-type.cpp b/tests/src/unit-custom-object-key-type.cpp index 4bf5182fa..f264a3971 100644 --- a/tests/src/unit-custom-object-key-type.cpp +++ b/tests/src/unit-custom-object-key-type.cpp @@ -156,11 +156,11 @@ struct object_for using type = std::map, pair_allocator>; // NOLINT(modernize-use-transparent-functors) }; -using json_full = nlohmann::basic_json::type>; -using json_no_eq = nlohmann::basic_json::type>; -using json_explicit = nlohmann::basic_json::type>; -using json_to_json = nlohmann::basic_json::type>; -using json_c_str = nlohmann::basic_json::type>; +using json_full = nlohmann::json::with_object_t::type>; +using json_no_eq = nlohmann::json::with_object_t::type>; +using json_explicit = nlohmann::json::with_object_t::type>; +using json_to_json = nlohmann::json::with_object_t::type>; +using json_c_str = nlohmann::json::with_object_t::type>; // a key that is long enough to need a length byte in CBOR and MessagePack const char* long_key_name(std::size_t i, std::string& storage);