Inheritance: global::System.Configuration.ApplicationSettingsBase
コード例 #1
0
        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
ファイル: ConsoleLogger.cs プロジェクト: staxmanade/StatLight
 public ConsoleLogger(LogChatterLevels logChatterLevel, Settings settings)
     : base(logChatterLevel)
 {
     _settings = settings;
 }
コード例 #3
0
ファイル: DebugLogger.cs プロジェクト: raittd/AgUnit
 public DebugLogger(LogChatterLevels logChatterLevel, Settings settings)
     : base(logChatterLevel)
 {
     this.settings = settings;
 }
コード例 #4
0
 public ConsoleResultHandler(ILogger logger, Settings settings)
 {
     _logger = logger;
     _settings = settings;
 }