public Online() { InitializeComponent(); txt_ip.Text = Properties.Settings.Default.ip; controller = new OnlineController(); controller.OnEnableButtons += new EnableButtons(OnEnableButtons); controller.OnUpdateMessage += new UpdateMessage(OnUpdateMessage); controller.OnSetupGame += new SetupGame(OnSetupGame); controller.OnStartGame += new StartGame(OnStartGame); controller.OnWait += new Wait(OnWait); }
public void Execute() { var controller = new OnlineController(); var cmd = new Appointment.Create() { ClientId = 123, VisitDate = new DateTime(2009, 08, 07), Notes = "test notes", }; var createdAppointment = new AppointmentBuilder().Build(); RootStub.StubExecute(cmd, createdAppointment); var result = (Appointment)controller.Execute(cmd).Data; Assert.That(result, Is.SameAs(createdAppointment)); }
void OnDestroy() { instance = null; }
void Awake() { instance = this; }