Esempio n. 1
0
        public void ToTypedRow_FromOtherRow()
        {
            var row1 = new MySimpleData
            {
                Name         = "Graf Orlov",
                DOB          = new DateTime(1980, 12, 11, 19, 23, 11),
                Certified    = true,
                ServiceYears = 37,
                Salary       = 123455.8712m
            };

            var str = row1.ToJSON(JSONWritingOptions.PrettyPrintRowsAsMap);

            Console.WriteLine(str);

            MySimpleData row2 = str.JSONToDynamic();

            Assert.IsTrue(row1.Equals(row2));
        }
Esempio n. 2
0
        public void ToTypedRow_FromOtherRow()
        {
            var row1 = new MySimpleData
            {
                Name         = "Graf Orlov",
                DOB          = new DateTime(1980, 12, 11, 19, 23, 11, DateTimeKind.Utc),
                Certified    = true,
                ServiceYears = 37,
                Salary       = 123455.8712m
            };

            var str = row1.ToJson(JsonWritingOptions.PrettyPrintRowsAsMap);

            str.See();

            MySimpleData row2 = str.JsonToDynamic();

            Aver.IsTrue(row1.Equals(row2));
        }
Esempio n. 3
0
        public void ToTypedRow_FromOtherRow()
        {
            var row1 = new MySimpleData
            {
              Name = "Graf Orlov",
              DOB = new DateTime(1980,12,11,19,23,11),
              Certified = true,
              ServiceYears = 37,
              Salary = 123455.8712m
            };

            var str = row1.ToJSON(JSONWritingOptions.PrettyPrintRowsAsMap);

            Console.WriteLine(str);

            MySimpleData row2 = str.JSONToDynamic();

            Assert.IsTrue(row1.Equals(row2));
        }