From: Tomek Mrugalski Date: Tue, 20 Dec 2016 13:27:32 +0000 (+0100) Subject: [5017] Split slash unicode into separate test. X-Git-Tag: trac5088_base~1^2~10 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=5602d52999441278b1b86a1b3f5ee31438869083;p=thirdparty%2Fkea.git [5017] Split slash unicode into separate test. --- diff --git a/src/bin/dhcp4/tests/parser_unittest.cc b/src/bin/dhcp4/tests/parser_unittest.cc index d594716744..ea31cd0fab 100644 --- a/src/bin/dhcp4/tests/parser_unittest.cc +++ b/src/bin/dhcp4/tests/parser_unittest.cc @@ -500,9 +500,13 @@ TEST(ParserTest, unicodeEscapes) { ASSERT_EQ(Element::string, result->getType()); EXPECT_EQ(ins, result->stringValue()); } +} +// This test checks that all represenations of a slash is recognized properly. +TEST(ParserTest, unicodeSlash) { // check the 4 possible encodings of solidus '/' - json = "\"/\\/\\u002f\\u002F\""; + ConstElementPtr result; + string json = "\"/\\/\\u002f\\u002F\""; ASSERT_NO_THROW( try { Parser4Context ctx;