Exemple #1
0
        public IHttpActionResult RequestStop(StopModel model)
        {
            var lift        = HttpContext.Current.Application["Lift"];
            var liftService = new LiftService((Lift)lift);

            liftService.RequestStop(model);

            HttpContext.Current.Application["Lift"] = liftService.Lift;
            return(Ok());
        }
Exemple #2
0
 public void SummonsToCurrentLevel()
 {
     _liftService.RequestStop(new StopModel(_liftService.Lift.CurrentLevel, DirectionEnum.Up));
     Assert.AreEqual(_liftService.Lift.SummonsUp.Count, 0, "Should not add a stop if already on the specified level");
 }