예제 #1
0
        public void TimeTillTickTest()
        {
            TimeSpan time = CycleService.TimeTillTick();

            Assert.IsTrue(time != TimeSpan.MaxValue);
            Assert.IsTrue(time > TimeSpan.Zero);
            Assert.IsTrue(time.Days < 7);
        }
예제 #2
0
        public void TimeRemainingTest()
        {
            string   timeRemaining = CycleService.TimeRemaining();
            TimeSpan time          = CycleService.TimeTillTick();

            Assert.IsTrue(timeRemaining.IndexOf("hour") > 0);
            if (time.Days == 0)
            {
                Assert.IsTrue(timeRemaining.IndexOf("minute") > 0);
            }
            else
            {
                Assert.IsTrue(timeRemaining.IndexOf("day") > 0);
            }
        }