Browse Source

[2571] Explain unit test for character 255.

Shane Kerr 12 years ago
parent
commit
f65147ed98
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/lib/cc/tests/data_unittests.cc

+ 3 - 0
src/lib/cc/tests/data_unittests.cc

@@ -91,6 +91,9 @@ TEST(Element, from_and_to_json) {
     sv.push_back("-1");
     sv.push_back("-1.234");
     sv.push_back("-123.456");
+    // We should confirm that our string handling is 8-bit clean.
+    // At one point we were using char-length data and comparing to EOF,
+    // which means that character '\xFF' would not parse properly.
     sv.push_back("\"\xFF\"");
 
     BOOST_FOREACH(const std::string& s, sv) {