12 instantiations of JsonParseException
Microsoft.Analyzers.Local (11)
ApiLifecycle\Json\JsonReader.cs (7)
81
_ => throw new
JsonParseException
(
193
_ => throw new
JsonParseException
(
206
throw new
JsonParseException
(
240
_ => throw new
JsonParseException
(
284
throw new
JsonParseException
(
319
throw new
JsonParseException
(
374
throw new
JsonParseException
(
ApiLifecycle\Json\TextScanner.cs (4)
52
throw new
JsonParseException
(ParsingError.IncompleteMessage, Position);
68
throw new
JsonParseException
(ParsingError.IncompleteMessage, Position);
115
throw new
JsonParseException
(
151
throw new
JsonParseException
(
Microsoft.Analyzers.Local.Tests (1)
Json\JsonParseExceptionTest.cs (1)
16
var ex = new
JsonParseException
();
20 references to JsonParseException
Microsoft.Analyzers.Local (3)
ApiLifecycle\Json\JsonParseException.cs (3)
33
/// Initializes a new instance of the <see cref="
JsonParseException
"/> class.
41
/// Initializes a new instance of the <see cref="
JsonParseException
"/> class with the given error type and position.
51
/// Initializes a new instance of the <see cref="
JsonParseException
"/> class with the given message, error type, and position.
Microsoft.Analyzers.Local.Tests (17)
Json\JsonParseExceptionTest.cs (1)
16
var
ex = new JsonParseException();
Json\JsonReaderTest.cs (7)
27
Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("{ \"x\": \"value\", \"x\": \"value\" }"));
70
var
ex = Assert.Throws<
JsonParseException
>(() => JsonReader.Parse("\"\\x\""));
75
ex = Assert.Throws<
JsonParseException
>(() => JsonReader.Parse("\"\\u11GA\""));
80
ex = Assert.Throws<
JsonParseException
>(() => JsonReader.Parse("\"\r\""));
89
var
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonReader.Parse("[ 1 2 ]"));
Json\JsonScannerTest.cs (7)
16
JsonParseException
ex;
18
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("trUe"));
23
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("tr"));
32
var
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("{ /1 }"));
39
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("{ // ignored text }"));
43
ex = Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("{ /* ignored text }"));
Json\JsonValueTest.cs (2)
349
Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse(string.Empty));
350
Assert.ThrowsAny<
JsonParseException
>(() => JsonValue.Parse("{"));