-
-
Notifications
You must be signed in to change notification settings - Fork 193
Configuration
GregFinzer edited this page Dec 21, 2017
·
2 revisions
CompareLogic logic = new CompareLogic();
logic.Config.MaxDifferences = 100;
ComparisonConfig config = new ComparisonConfig();
config.MaxDifferences = 100;
CompareLogic logic = new CompareLogic(config);
Example
[Test]
public void LoadConfigurationTest()
{
//Arrange
CompareLogic compareLogic = new CompareLogic();
string filePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "config.json");
compareLogic.Config.CaseSensitive = false;
compareLogic.SaveConfiguration(filePath);
//Act
compareLogic.Config = new ComparisonConfig(); //Wipe out the current config
compareLogic.LoadConfiguration(filePath);
//Assert
Assert.IsFalse(compareLogic.Config.CaseSensitive);
}
Edit the resource file for the application settings