Наследование: global::System.Configuration.ApplicationSettingsBase
        public void Valid_setting_specified_should_override_value()
        {
            var settings = new Settings();

            var overriddenSettings = new Dictionary<string, string>
                                         {
                                             {"MaxWaitTimeAllowedBeforeCommunicationErrorSent", "00:00:20"},
                                         };

            var settingsOverrideApplicator = new SettingsOverrideApplicator(TestLogger);

            settingsOverrideApplicator.ApplySettingsFrom(overriddenSettings, settings);

            settings.MaxWaitTimeAllowedBeforeCommunicationErrorSent
                .ShouldNotEqual(Settings.Default.MaxWaitTimeAllowedBeforeCommunicationErrorSent);

            settings.MaxWaitTimeAllowedBeforeCommunicationErrorSent.ShouldEqual(TimeSpan.FromSeconds(20));
        }
Пример #2
0
 public ConsoleLogger(LogChatterLevels logChatterLevel, Settings settings)
     : base(logChatterLevel)
 {
     _settings = settings;
 }
Пример #3
0
 public DebugLogger(LogChatterLevels logChatterLevel, Settings settings)
     : base(logChatterLevel)
 {
     this.settings = settings;
 }
Пример #4
0
 public ConsoleResultHandler(ILogger logger, Settings settings)
 {
     _logger = logger;
     _settings = settings;
 }