Пример #1
0
        public void Setup()
        {
            heater_     = Substitute.For <IHeater>();
            tempSensor_ = Substitute.For <ITempSensor>();

            ecs_ = new LegacyCore.ECS(25, tempSensor_, heater_);
        }
Пример #2
0
        public void Setup()
        {
            sensor = Substitute.For <ITempSensor>();
            heater = Substitute.For <IHeater>();

            uut = new ECS(20, sensor, heater);
        }
Пример #3
0
        public void SetUp()
        {
            _heater     = Substitute.For <IHeater>();
            _tempSensor = Substitute.For <ITempSensor>();

            _uut = new ECS(25, _tempSensor, _heater);
        }
 public void Setup()
 {
     _tempSensor = Substitute.For <ITempSensor>();
     _heater     = Substitute.For <IHeater>();
     _window     = Substitute.For <IWindow>();
     _ecsSystem  = new ECS(10, 100, _tempSensor, _heater, _window);
 }
 public void SetUp()
 {
     _tempSensor           = new StubTempSensor();
     _heater               = new StubHeater();
     _window               = new StubWindow();
     _myEnCoSy_with_window = new EnCoSy_with_window(15, 25, _tempSensor, _heater, _window);
 }
Пример #6
0
 public void Setup()
 {
     heater_     = Substitute.For <IHeater>();
     tempSensor_ = Substitute.For <ITempSensor>();
     temp        = 28;
     uut         = new EnvironmentControlSystem(temp, tempSensor_, heater_);
 }
Пример #7
0
 public void Setup()
 {
     _fakeHeater     = NSubstitute.Substitute.For <IHeater>();
     _fakeTempSensor = NSubstitute.Substitute.For <ITempSensor>();
     _fakeTempSensor.GetTemp().Returns(30);
     _fakeWindow = NSubstitute.Substitute.For <IWindow>();
 }
Пример #8
0
        public void Setup()
        {
            _heater     = Substitute.For <IHeater>();
            _tempSensor = Substitute.For <ITempSensor>();

            _uut = new global::ECS.Legacy.ECS(25, 28, _tempSensor, _heater);
        }
Пример #9
0
 public CoffeeMachine(IGrinder grinder, IHeater heater, IPump pump, ITank tank)
 {
     this.grinder = grinder;
     this.heater  = heater;
     this.pump    = pump;
     this.tank    = tank;
 }
Пример #10
0
 public void Setup()
 {
     heater = NSubstitute.Substitute.For <IHeater>();
     //tempSensor = NSubstitute.Substitute.For<ITempSensor>();
     fakeTempSensor = new FakeTempSensor();
     uut            = new ECS.Legacy.ECS(_threshold, fakeTempSensor, heater);
 }
Пример #11
0
 public ECS(int minThr, int maxThr, ISensor tempSensor, IHeater heater)
 {
     _minThreshold = minThr;
     _maxThreshold = maxThr;
     _tempSensor   = tempSensor;
     _heater       = heater;
 }
Пример #12
0
        public void Setup()
        {
            _heater     = Substitute.For <IHeater>();
            _tempSource = Substitute.For <ITempSensor>();

            _uut = new ECSControl(25, _tempSource, _heater);
        }
Пример #13
0
 public void Setup()
 {
     _fakeheater  = Substitute.For <IHeater>();
     _fakeWindow  = Substitute.For <IWindow>();
     _faketempSen = Substitute.For <ITempSensor>();
     _ecs         = new ECS(_fakeheater, _faketempSen, _fakeWindow, InitializeHeaterThreshold, InitializeWindowThreshold);
 }
        public void Setup()
        {
            _heater     = Substitute.For <IHeater>();
            _tempSensor = Substitute.For <ITempSensor>();

            _uut = new HomeControl.Control(_heater, _tempSensor);
        }
Пример #15
0
 //Constructor injection
 public ECS(int thr, IHeater heater, ITempSensor tempSensor, IWindow window)
 {
     SetThreshold(thr);
     _heater     = heater;
     _tempSensor = tempSensor;
     _Window     = window;
 }
 public void Setup()
 {
     //Arrange
     _fakeHeater     = Substitute.For <IHeater>();
     _fakeTempSensor = Substitute.For <ITempSensor>();
     uut             = new ECS(_fakeTempSensor, _fakeHeater, 10);
 }
Пример #17
0
 public void Setup()
 {
     _heater     = Substitute.For <IHeater>();
     _tempsensor = Substitute.For <ITempSensor>();
     _uut        = new Ecs(25, _tempsensor, _heater);
     //Ecs_ctor_inject();
 }
Пример #18
0
 public void Setup()
 {
     _heater = Substitute.For <IHeater>();
     _sensor = Substitute.For <ITempSensor>();
     _window = Substitute.For <IWindow>();
     _uut    = new ECS(25, _heater, _sensor, _window);
 }
Пример #19
0
        public void Setup()
        {
            _fakeHeater     = Substitute.For <IHeater>();
            _fakeTempSensor = Substitute.For <ITempSensor>();

            _uut = new ECS(25, _fakeTempSensor, _fakeHeater);
        }
Пример #20
0
 public ECS(int thr,
            ITempSensor tempSensor,
            IHeater heater)
 {
     SetThreshold(thr);
     _tempSensor = tempSensor;
     _heater     = heater;
 }
Пример #21
0
        public void Setup()
        {
            uutHeater     = Substitute.For <IHeater>();
            uutTempSensor = Substitute.For <ITempSensor>();
            uutWindow     = Substitute.For <IWindow>();

            uut = new Ecs(25, 30, uutTempSensor, uutHeater, uutWindow);
        }
 public void ChangeState(IDoor door, ILight light, IHeater heater, IStartButton startButton, ITimer timer)
 {
     door.CloseDoor();
     light.TurnOnLight();
     heater.TurnOn();
     startButton.ButtonIsPressed();
     timer.Start();
 }
Пример #23
0
        public WaterBoiler(IThermostat thermostat, IHeater heater)
        {
            this.thermostat = thermostat;
            this.heater     = heater;

            this.thermostat.TooHot  += this.OnThermostatTooHot;
            this.thermostat.TooCold += this.OnThermostatTooCold;
        }
 public ECS(int heaterThr, int windowThr, ITempSensor tempSensor, IHeater heater, IWindow window)
 {
     SetHeaterThreshold(heaterThr);
     SetWindowThreshold(windowThr);
     _tempSensor = tempSensor;
     _heater     = heater;
     _window     = window;
 }
Пример #25
0
 public ECSClass(int thr, int upperthr, ITempSensor tempSensor, IHeater heater, IWindow window)
 {
     SetThreshold(thr);
     SetUpperThreshold(upperthr);
     _tempSensor = tempSensor;
     _heater     = heater;
     _window     = window;
 }
Пример #26
0
        public void Setup()
        {
            _heater = Substitute.For <IHeater>();
            _sensor = Substitute.For <ISensor>();
            _window = Substitute.For <IWindow>();

            _uut = new RefactoredECS.ECS(_sensor, _heater, _window, 30, 50);
        }
Пример #27
0
            public void Setup()
            {
                _thr        = 25;
                _fakeSensor = Substitute.For <ISensor>(); //Create substitute, indeholder inddirekte "new"
                _fakeHeater = Substitute.For <IHeater>();

                UUT = new ECS(_thr, _fakeSensor, _fakeHeater);
            }
Пример #28
0
        public void Setup()
        {
            _heater = Substitute.For <IHeater>();
            _sensor = Substitute.For <ITempSensor>();
            _window = Substitute.For <IWindow>();

            _uut = new ECS(_sensor, _heater, _window, _lowerTemperatureThreshold, _upperTemperatureThreshold);
        }
Пример #29
0
        public TaskG()
        {
            _currentTemperatureProvider  = MockRepository.GenerateMock <ICurrentTemperatureProvider>();
            _temperatureSettingsProvider = MockRepository.GenerateMock <ITemperatureSettingsProvider>();
            _heater = MockRepository.GenerateMock <IHeater>();

            _thermostat = new Thermostat(_currentTemperatureProvider, _temperatureSettingsProvider, _heater);
        }
Пример #30
0
 public void Setup()
 {
     _heater     = Substitute.For <IHeater>();
     _tempSensor = Substitute.For <ITempSensor>();
     _window     = Substitute.For <IWindow>();
     _uut        = new ECSControl(_threshold, _tempSensor, _heater, _window);
     _uut.SetThreshold(25);
 }
Пример #31
0
 public Menu(IFridge fridge, IHeater heater, IFreezer freezer, IAirConditioning airConditioning, ITV tV, IMediaPlayer mediaPlayer)
 {
     Fridge = fridge;
     Heater = heater;
     Freezer = freezer;
     AirConditioning = airConditioning;
     TV = tV;
     MediaPlayer = mediaPlayer;
 }
 public Thermosiphon(IHeater heater)
 {
     this.heater = heater;
 }