// 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);
        }
Exemplo n.º 2
0
        private static void VerifyNavigatorWithCurratedDoc(string path, bool performExtraChecks = true)
        {
            path = string.Format("TestJsons/{0}", path);
            string json = TextFileConcatenation.ReadMultipartFile(path);

#if true
            json = JsonTestUtils.RandomSampleJson(json, maxNumberOfItems: 1);
#endif

            JsonNavigatorTests.VerifyNavigator(json, performExtraChecks);
        }