Example #1
0
        public void RoundTripISerializable()
        {
            var input  = new TestClassSerializable(10, "Hello", 20, true);
            var json   = new JsonSerializer(true).Serialize(input);
            var output = new JsonDeserializer().Deserialize <TestClassSerializable>(json);

            input.AssertMatches(output);
        }
        public void CanDeserialiseISerializable()
        {
            var input  = new TestClassSerializable(10, "Hello", 20, true);
            var json   = JsonConvert.SerializeObject(input);
            var output = new JsonDeserializer().Deserialize <TestClassSerializable>(json);

            input.AssertMatches(output);
        }