public void GivenANasLog_WhenSettingAnError_ThenShouldReturnTheTypeRelativeToTheError() { // Arrange & Act var logNas = new NasLog(null) { IsError = true }; // Assert Assert.That(logNas.LogType, Is.EqualTo("error"), $"LogType is not well defined depending on {nameof(NasLog.IsError)} field."); }
public NasSaveLogViewModel() { _ = int.TryParse(ConfigurationManager.AppSettings["WaitingTimeAfterSavingInMs"], out var waitingTimeAfterSaving); WaitingTimeAfterSavingInMs = waitingTimeAfterSaving; Locale = LocaleHelper.MakeLocales(ConfigurationManager.AppSettings["Locale"]); _previousLogNasPath = ConfigurationManager.AppSettings["NasSaveLogFolder"]; LogNas = new NasLog(_appName); LogObjectViewModel = new NasLogViewModel(); }