test: ensure the version numbers agree
diff --git a/src/test_lib_json/main.cpp b/src/test_lib_json/main.cpp
index 991c247..540e66b 100644
--- a/src/test_lib_json/main.cpp
+++ b/src/test_lib_json/main.cpp
@@ -3916,6 +3916,16 @@
   }
 }
 
+class VersionTest : public JsonTest::TestCase {};
+
+JSONTEST_FIXTURE_LOCAL(VersionTest, VersionNumbersMatch) {
+  std::ostringstream vstr;
+  vstr << JSONCPP_VERSION_MAJOR << '.'
+       << JSONCPP_VERSION_MINOR << '.'
+       << JSONCPP_VERSION_PATCH;
+  JSONTEST_ASSERT_EQUAL(vstr.str(), std::string(JSONCPP_VERSION_STRING));
+}
+
 #if defined(__GNUC__)
 #pragma GCC diagnostic pop
 #endif