예제 #1
0
        public void DefaultFormatTest2()
        {
            DateTimeColumnFormat format = new DateTimeColumnFormat();
            var result = format.Format(new DateTime(1900, 1, 1, 0, 0, 0, 0));

            Assert.AreEqual("1900-01-01", result);
        }
예제 #2
0
        public void DefaultFormatTest3()
        {
            DateTimeColumnFormat format = new DateTimeColumnFormat();
            var result = format.Format(new DateTime(2000, 5, 1, 9, 30, 10, 0));

            Assert.AreEqual("2000-05-01 09:30:10", result);
        }
예제 #3
0
        public void FormatNullTest()
        {
            DateTimeColumnFormat format = new DateTimeColumnFormat();
            var result = format.Format(DBNull.Value);

            Assert.AreEqual(ColumnFormat.NullText, result);
        }