public void Given()
 {
     myConfig = new TwentyFourSevenTimerConfig
                    {
                        Monday = "12:34:56,12:34:56,00:00:01"
                    };
     myTimer = new TwentyFourSevenTimer(myConfig);
 }
Exemplo n.º 2
0
        public TwentyFourSevenTimer(TwentyFourSevenTimerConfig config, INow time)
        {
            myTimeReference = time;
            myConfig = config;

            Alarms = ParseConfig();
            LastAlarmTriggered = myTimeReference.Now();
        }
Exemplo n.º 3
0
        public TwentyFourSevenTimer(TwentyFourSevenTimerConfig config, INow time)
        {
            myTimeReference = time;
            myConfig        = config;

            Alarms             = ParseConfig();
            LastAlarmTriggered = myTimeReference.Now();
        }
 public void Given()
 {
     myConfig = new TwentyFourSevenTimerConfig
                    {
                        Weekend = "12:34:56,00:00:01",
                        Saturday = "00:00:02",
                        Sunday = "00:00:03"
                    };
     myTimer = new TwentyFourSevenTimer(myConfig);
 }
 public void Given()
 {
     myConfig = new TwentyFourSevenTimerConfig
     {
         Everyday = "00:00:01,00:00:02,00:00:03,00:00:04,00:00:05,00:01:01,00:02:01"
     };
     myTimer = new TwentyFourSevenTimer(myConfig,
         new FakeNow(DateTime.Now.SetTimeOfDay(0,0,2)));
     Thread.Sleep(5000);
     myTriggeredAlarms = myTimer.Triggered();
 }
Exemplo n.º 6
0
 public TwentyFourSevenTimer(TwentyFourSevenTimerConfig config)
     : this(config, new RealNow())
 {
 }
Exemplo n.º 7
0
 public TwentyFourSevenTimer(TwentyFourSevenTimerConfig config)
     : this(config, new RealNow())
 {
 }