public void ThrowNotDockedExceptionIfInstrumentNotDocked() { // arrange action = new InstrumentSettingsUpdateAction(); Initialize(); InstrumentSettingsUpdateOperation operation = new InstrumentSettingsUpdateOperation(action); // act and assert Xunit.Assert.Throws <InstrumentNotDockedException>(() => operation.Execute()); }
public void ThrowNotDockedExceptionIfInstrumentTypeIsUnknown() { // arrange action = new InstrumentSettingsUpdateAction(); instrument = Helper.GetInstrumentForTest(DeviceType.Unknown); Initialize(); InstrumentSettingsUpdateOperation operation = new InstrumentSettingsUpdateOperation(action); // act and assert Xunit.Assert.Throws <InstrumentNotDockedException>(() => operation.Execute()); }
public void ThrowNotDockedExceptionIfInstrumentSerialNumberIsEmpty() { // arrange action = new InstrumentSettingsUpdateAction(); dockingStation = Helper.GetDockingStationForTest(DeviceType.MX4); instrument = Helper.GetInstrumentForTest(DeviceType.MX4); instrument.SerialNumber = string.Empty; Initialize(); InstrumentSettingsUpdateOperation operation = new InstrumentSettingsUpdateOperation(action); // act and assert Xunit.Assert.Throws <InstrumentNotDockedException>(() => operation.Execute()); }
public InstrumentSettingsUpdateOperation(InstrumentSettingsUpdateAction instrumentSettingsUpdateAction) : base(instrumentSettingsUpdateAction) { }