-Built-in converters inherit from JsonConverter

-Fixed writing null values by XmlNodeConverter and RegexConverter
-Tests
-Documentation
This commit is contained in:
James Newton-King
2017-08-12 20:17:28 +12:00
parent 0996a59f8c
commit 946b43fab8
15 changed files with 268 additions and 36 deletions
@@ -45,6 +45,18 @@ namespace Newtonsoft.Json.Tests.Converters
{
public class DataTableConverterTests : TestFixtureBase
{
[Test]
public void WriteJsonNull()
{
StringWriter sw = new StringWriter();
JsonTextWriter jsonWriter = new JsonTextWriter(sw);
DataTableConverter converter = new DataTableConverter();
converter.WriteJson(jsonWriter, null, null);
StringAssert.AreEqual(@"null", sw.ToString());
}
[Test]
public void Deserialize()
{