diff options
| author | Vasily Gerasimov <[email protected]> | 2022-02-10 16:49:10 +0300 | 
|---|---|---|
| committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:49:10 +0300 | 
| commit | 1eb755fbca92172a6aec2f57371b2b3a19dfab43 (patch) | |
| tree | 5d5cb817648f650d76cf1076100726fd9b8448e8 /library/cpp/scheme/tests | |
| parent | 6cdc8f140213c595e4ad38bc3d97fcef1146b8c3 (diff) | |
Restoring authorship annotation for Vasily Gerasimov <[email protected]>. Commit 2 of 2.
Diffstat (limited to 'library/cpp/scheme/tests')
| -rw-r--r-- | library/cpp/scheme/tests/ut/scheme_json_ut.cpp | 12 | ||||
| -rw-r--r-- | library/cpp/scheme/tests/ut/scheme_ut.cpp | 10 | 
2 files changed, 11 insertions, 11 deletions
| diff --git a/library/cpp/scheme/tests/ut/scheme_json_ut.cpp b/library/cpp/scheme/tests/ut/scheme_json_ut.cpp index 37d635238e1..daeb2654f9a 100644 --- a/library/cpp/scheme/tests/ut/scheme_json_ut.cpp +++ b/library/cpp/scheme/tests/ut/scheme_json_ut.cpp @@ -137,7 +137,7 @@ Y_UNIT_TEST_SUITE(TSchemeJsonTest) {          NSc::TValue b = NSc::TValue::FromJsonValue(a.ToJsonValue());          UNIT_ASSERT_JSON_EQ_JSON(a, b);      } -  +      Y_UNIT_TEST(TestJsonEmptyContainers) {          {              NSc::TValue a = NSc::NUt::AssertFromJson("{a:[]}"); @@ -153,9 +153,9 @@ Y_UNIT_TEST_SUITE(TSchemeJsonTest) {      Y_UNIT_TEST(TestDuplicateKeys) {          const TStringBuf duplicatedKeys = "{\"a\":[{\"b\":1, \"b\":42}]}"; -        UNIT_ASSERT_NO_EXCEPTION(NSc::TValue::FromJsonThrow(duplicatedKeys));  -        UNIT_ASSERT_EXCEPTION(NSc::TValue::FromJsonThrow(duplicatedKeys, NSc::TValue::JO_PARSER_DISALLOW_DUPLICATE_KEYS), yexception);  -        UNIT_ASSERT(NSc::TValue::FromJson(duplicatedKeys).IsDict());  -        UNIT_ASSERT(NSc::TValue::FromJson(duplicatedKeys, NSc::TValue::JO_PARSER_DISALLOW_DUPLICATE_KEYS).IsNull());  -    }  +        UNIT_ASSERT_NO_EXCEPTION(NSc::TValue::FromJsonThrow(duplicatedKeys)); +        UNIT_ASSERT_EXCEPTION(NSc::TValue::FromJsonThrow(duplicatedKeys, NSc::TValue::JO_PARSER_DISALLOW_DUPLICATE_KEYS), yexception); +        UNIT_ASSERT(NSc::TValue::FromJson(duplicatedKeys).IsDict()); +        UNIT_ASSERT(NSc::TValue::FromJson(duplicatedKeys, NSc::TValue::JO_PARSER_DISALLOW_DUPLICATE_KEYS).IsNull()); +    }  }; diff --git a/library/cpp/scheme/tests/ut/scheme_ut.cpp b/library/cpp/scheme/tests/ut/scheme_ut.cpp index 20fe460948d..1a5d07c31bc 100644 --- a/library/cpp/scheme/tests/ut/scheme_ut.cpp +++ b/library/cpp/scheme/tests/ut/scheme_ut.cpp @@ -863,17 +863,17 @@ Y_UNIT_TEST_SUITE(TSchemeTest) {      }      Y_UNIT_TEST(TestGetNoAdd) { -        NSc::TValue v = NSc::NUt::AssertFromJson("{a:[null,-1,2,3.4],b:3,c:{d:5}}");  +        NSc::TValue v = NSc::NUt::AssertFromJson("{a:[null,-1,2,3.4],b:3,c:{d:5}}");          UNIT_ASSERT(v.GetNoAdd("a") != nullptr);          UNIT_ASSERT(v.GetNoAdd("b") != nullptr);          UNIT_ASSERT(v.GetNoAdd("c") != nullptr);          UNIT_ASSERT(v.GetNoAdd("d") == nullptr);          UNIT_ASSERT(v.GetNoAdd("value") == nullptr); -  +          NSc::TValue* child = v.GetNoAdd("c");          UNIT_ASSERT(child != nullptr);          (*child)["e"]["f"] = 42; -        const NSc::TValue expectedResult = NSc::NUt::AssertFromJson("{a:[null,-1,2,3.4],b:3,c:{d:5,e:{f:42}}}");  -        UNIT_ASSERT_VALUES_EQUAL(v, expectedResult);  -    }  +        const NSc::TValue expectedResult = NSc::NUt::AssertFromJson("{a:[null,-1,2,3.4],b:3,c:{d:5,e:{f:42}}}"); +        UNIT_ASSERT_VALUES_EQUAL(v, expectedResult); +    }  }; | 
