diff options
author | Jon Skeet <jonskeet@google.com> | 2018-03-01 13:45:13 +0000 |
---|---|---|
committer | Jon Skeet <jonskeet@google.com> | 2018-03-01 13:45:13 +0000 |
commit | 5140bae3834c40208e44b1eeb947485a832387a7 (patch) | |
tree | be0dd8b01bcb96517a176fd5d40de1e539083a7b /conformance/conformance_test.cc | |
parent | 822b924d593f67d2536c7bdeaf55cedf614da244 (diff) |
Add conformance test for null value in list JSON
Diffstat (limited to 'conformance/conformance_test.cc')
-rw-r--r-- | conformance/conformance_test.cc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/conformance/conformance_test.cc b/conformance/conformance_test.cc index e4b046dc..d44c909a 100644 --- a/conformance/conformance_test.cc +++ b/conformance/conformance_test.cc @@ -2321,6 +2321,24 @@ bool ConformanceTestSuite::RunSuite(ConformanceTestRunner* runner, } )"); RunValidJsonTest( + "ValueAcceptListWithNull", REQUIRED, + R"({"optionalValue": ["x", null, "y"]})", + R"( + optional_value: { + list_value: { + values: { + string_value: "x" + } + values: { + null_value: NULL_VALUE + } + values: { + string_value: "y" + } + } + } + )"); + RunValidJsonTest( "ValueAcceptObject", REQUIRED, R"({"optionalValue": {"value": 1}})", R"( |