Пример #1
0
        public void FormatString_YearToMonth()
        {
            var interval = PrimitiveTypes.YearToMonth();

            var s = interval.ToString();

            Assert.AreEqual("INTERVAL YEAR TO MONTH", s);
        }
Пример #2
0
        public void SerializeObject_YearToMonth_Null()
        {
            var type = PrimitiveTypes.YearToMonth();
            var obj  = SqlYearToMonth.Null;

            var stream = new MemoryStream();

            type.SerializeObject(stream, obj);

            stream.Seek(0, SeekOrigin.Begin);

            var serialized = type.DeserializeObject(stream);

            Assert.AreEqual(obj, serialized);
        }