Beispiel #1
0
        public void DobFromAgeTest1()
        {
            var atDate = new DateTime(2010, 6, 11, 10, 15, 16, 178);

            var expected = new DateTime(2007, 1, 1);
            var actual   = DateTimeExtensions.DobFromAge(3, atDate);

            Assert.AreEqual(expected, actual);
        }
Beispiel #2
0
        public void DobFromAgeTest()
        {
            SystemTime.NowFunction = () => new DateTime(2010, 6, 11, 10, 15, 16, 178);

            var expected = new DateTime(2007, 1, 1);
            var actual   = DateTimeExtensions.DobFromAge(3);

            Assert.AreEqual(expected, actual);
        }