コード例 #1
0
        // Checks to see if we can go from a JsonReader to a NewtonsoftWriter and get back the original document and visa versa
        private void RoundTripTestCuratedJson(string path)
        {
            path = string.Format("TestJsons/{0}", path);
            string json = TextFileConcatenation.ReadMultipartFile(path);

#if true
            json = JsonTestUtils.RandomSampleJson(json, seed: 42, maxNumberOfItems: 100);
#endif
            JsonRoundTripsTests.MultiSerializationRoundTrip(json);
        }
コード例 #2
0
 private static void PerformRoundTripTest(string input)
 {
     // Do the actual roundtrips
     JsonRoundTripsTests.MultiSerializationRoundTrip(input);
 }
コード例 #3
0
 private static void PerformRoundTripTest(string input, IReadOnlyList <JsonToken> tokens)
 {
     // Do the actual roundtrips
     JsonRoundTripsTests.MultiSerializationRoundTrip(input);
 }