-Fixed deserializing large nullable UInt64 values

This commit is contained in:
James Newton-King
2015-02-25 20:44:07 +13:00
parent dd611a9ca5
commit 376ab4dbb5
2 changed files with 23 additions and 1 deletions
@@ -8588,6 +8588,28 @@ Path '', line 1, position 1.");
Assert.AreEqual("derived", d.DerivedProperty);
}
[Test]
public void DeserializeNullableUnsignedLong()
{
NullableLongTestClass instance = new NullableLongTestClass
{
Value = ulong.MaxValue
};
string output = JsonConvert.SerializeObject(instance);
NullableLongTestClass result = JsonConvert.DeserializeObject<NullableLongTestClass>(output);
Assert.AreEqual(ulong.MaxValue, result.Value);
}
public class NullableLongTestClass
{
public ulong? Value
{
get;
set;
}
}
#if !NETFX_CORE
[Test]
public void MailMessageConverterTest()