public void TryGetCurrentAutoStart_ReturnsFalseIfNotFound() { var ret = Service.TryGetCurrentAutoStart(Guid, out AutoStartEntry retAutoStart); Assert.IsFalse(ret); Assert.IsNull(retAutoStart); }
public void Disable(Guid id) { Task.Run(() => { Logger.Info("{id} should be disabled", id); if (AutoStartService.TryGetCurrentAutoStart(id, out AutoStartEntry autoStart)) { Disable(autoStart); } else { var message = "Failed to get auto start to disable"; Logger.Error(message); MessageService.ShowError(message); } }); }