Adds JsonElement.ValueEquals / JsonProperty.NameEquals APIs, (dotnet/corefx#37911)
authorMaryam Ariyan <maryam.ariyan@microsoft.com>
Tue, 4 Jun 2019 00:21:10 +0000 (17:21 -0700)
committerGitHub <noreply@github.com>
Tue, 4 Jun 2019 00:21:10 +0000 (17:21 -0700)
commitab1d04e32a4d932205b2ffa3dd384282fb8e64be
tree551bcaa40b597681b065703aec2810dbb233cf00
parent5fb8b93b66bbb97dd26aa18c2825cda890475d1a
Adds JsonElement.ValueEquals / JsonProperty.NameEquals APIs, (dotnet/corefx#37911)

* - Rename Utf8JsonReader.TextEquals to Utf8JsonReader.ValueTextEquals
- Implement JsonElement.ValueEquals and add code coverage
- Reuse logic for JsonProperty and add code coverage
- improve header documentation
- cleanup tests

Commit migrated from https://github.com/dotnet/corefx/commit/f09135a373caa94eca1566f7ad497aaf19587140
src/libraries/System.Text.Json/ref/System.Text.Json.cs
src/libraries/System.Text.Json/src/System/Text/Json/Document/JsonDocument.cs
src/libraries/System.Text.Json/src/System/Text/Json/Document/JsonElement.cs
src/libraries/System.Text.Json/src/System/Text/Json/Document/JsonProperty.cs
src/libraries/System.Text.Json/src/System/Text/Json/Reader/Utf8JsonReader.cs
src/libraries/System.Text.Json/tests/JsonDocumentTests.cs
src/libraries/System.Text.Json/tests/System.Text.Json.Tests.csproj
src/libraries/System.Text.Json/tests/TestClasses.ClassWithComplexObjects.cs
src/libraries/System.Text.Json/tests/Utf8JsonReaderTests.ValueTextEquals.cs [moved from src/libraries/System.Text.Json/tests/Utf8JsonReaderTests.TextEquals.cs with 77% similarity]
src/libraries/System.Text.Json/tests/Utf8JsonReaderTests.cs