public static object ParseValue(string jsonString) { using (var instance = new JsonParser(jsonString)) { return instance.ParseValue(); } }
public static void ParseString1() { string str = JsonParser.ParseValue("\"test\"") as string; Assert.AreEqual("test", str); }
public static void ParseString2() { string str = JsonParser.ParseValue(" \" \\\"Test\\\" \" ") as string; Assert.AreEqual(" \"Test\" ", str); }
public static void ParseString4() { string str = JsonParser.ParseValue("Test\"") as string; Assert.IsNull(str); }
public static void ParseUTF8String1() { string str = JsonParser.ParseValue("\"\\u20AC \\u00F6 \\u00DC \\u00E9\"") as string; Assert.AreEqual("€ ö Ü é", str); }