예제 #1
0
        public void PercentOfYear()
        {
            DateTime time = new DateTime(2009, 7, 1, 0, 0, 0);

            Assert.True(BowieMath.CompareFloats(0.5f, BowieTime.PercentOfYear(time), 0.01f));
        }
예제 #2
0
 public void OneAndThreeAreMoreThanOneApart()
 {
     Assert.False(BowieMath.CompareFloats(1, 3, 1));
 }
예제 #3
0
        public void PercentOfDay()
        {
            DateTime time = new DateTime(2008, 3, 1, 12, 0, 0);

            Assert.True(BowieMath.CompareFloats(0.5f, BowieTime.PercentOfDay(time), 0.0001f));
        }
예제 #4
0
 public void OneAndThreeAreLessThanFourApart()
 {
     Assert.True(BowieMath.CompareFloats(1, 3, 4));
 }