public void DeleteConfiguration_SetDefaultConfigThenDelete_ConfigIsNullWhenLoaded() { // Load initial test config (should be null) var config = _manager.LoadConfiguration(); Assert.IsNull(config); // Set the default configuration (localhost only) _manager.InitializeConfiguration(); // Load the configuration (should be the default config with only localhost) var loadedConfig = _manager.LoadConfiguration(); Assert.IsNotNull(loadedConfig); Assert.IsTrue(loadedConfig.CategoryList.First().ServerList.First().Name.Equals("localhost")); // Delete the configuration _manager.DeleteConfiguration(); // Load the configuration (should be null) var loadedConfig2 = _manager.LoadConfiguration(); Assert.IsNull(loadedConfig2); }
public void Init() { _manager = new ServerConfigurationManager(new ServerConfigurationXMLConverter()); _manager.DeleteConfiguration(); }