public void MediatorTestCase()
        {
            var ems = new EngineManagementSystem();
            var ignition = new Ignition(ems);
            var accelerator = new Accelerator(ems);
            var brake = new Brake(ems);
            var gearbox = new GearBox(ems);

            //Log
            ignition.Start();
            accelerator.AccelerateToSpeed(40);
            accelerator.AccelerateToSpeed(80);
            brake.Apply();
            ignition.Stop();
            //todo: define tests
        }
Exemplo n.º 2
0
 // registration
 public virtual void RegisterIgnition(Ignition ignition)
 {
     _ignition = ignition;
 }