public void TestCleanup() { if (_svc != null) { _svc.Stop(); } }
private async void StopService(bool logerror = true) { try { Logger.PrintText(new Run("Finalizando serviço..."), new Run(" --> "), new DateOptions(TextDecorationOptions.BOLD)); bool status = OwinService.Stop(); await ServiceStatusUC.ChangeStatus(!status); } catch (Exception ex) { if (logerror) { MessageBox.Show(ex.ToString(), "Erro ao finalizar serviço", MessageBoxButton.OK, MessageBoxImage.Error); Logger.PrintText(new Run("Erro na finalização do serviço..."), new Run(" --> "), new DateOptions(TextDecorationOptions.BOLD)); } } }
public void Dispose() { _owinService.Stop(); }