THRIFT-5772: UUID support for c++ #2952
Client: cpp
Patch: CJCombrink
This closes #2952
diff --git a/lib/cpp/test/ToStringTest.cpp b/lib/cpp/test/ToStringTest.cpp
index 736b33c..68c82ad 100644
--- a/lib/cpp/test/ToStringTest.cpp
+++ b/lib/cpp/test/ToStringTest.cpp
@@ -160,4 +160,13 @@
"ListBonks(bonk=[Bonk(message=a, type=0), Bonk(message=b, type=0)])");
}
+BOOST_AUTO_TEST_CASE(generated_uuid_to_string) {
+ thrift::test::CrazyNesting l;
+ l.uuid_field = "{4b686716-5f20-4deb-8ce0-9eaf379e8a3d}";
+
+ BOOST_CHECK_EQUAL(to_string(l),
+ "CrazyNesting(string_field=, set_field=<null>, list_field=[], binary_field=, "
+ "uuid_field={4b686716-5f20-4deb-8ce0-9eaf379e8a3d})");
+}
+
BOOST_AUTO_TEST_SUITE_END()