-Added Path to JsonReaderException/JsonSerializationException messages

-Added JsonException
-Fixed all Exceptions thrown to be more specific
This commit is contained in:
James Newton-King
2012-04-21 17:25:44 +12:00
parent c120bf530d
commit a7bddf989f
69 changed files with 1400 additions and 1161 deletions
@@ -86,16 +86,16 @@ namespace Newtonsoft.Json.Tests.Linq
}
[Test]
[ExpectedException(typeof(ArgumentException)
#if !NETFX_CORE
, ExpectedMessage = "Could not determine JSON object type for type System.String[]."
#endif
)]
public void JObjectPropertyNameWithNonToken()
{
dynamic d = new JObject();
ExceptionAssert.Throws<ArgumentException>(
"Could not determine JSON object type for type System.String[].",
() =>
{
dynamic d = new JObject();
d.First = new [] {"One", "II", "3"};
d.First = new[] { "One", "II", "3" };
});
}
[Test]