public void AsDictionaryTest()
 {
     var config = new Config(_configPath);
     ISection section = config.GetSection("Section 0");
     ISetting setting = section.GetSetting("Setting 1");
     Dictionary<int, string> actual = setting.AsDictionary<int, string>();
     Assert.AreEqual(5, actual.Count);
 }
 public void AsArrayTest()
 {
     var config = new Config(_configPath);
     ISection section = config.GetSection("Section 0");
     ISetting setting = section.GetSetting("Setting 0");
     string[] actual = setting.AsArray<string>();
     Assert.AreEqual(5, actual.Length);
 }
Esempio n. 3
0
 public void ValueTest()
 {
     var config = new Config(_configPath);
     ISection section = config.GetSection("Section 2");
     ISetting setting = section.GetSetting("Setting 3");
     Assert.AreEqual("3", setting.Value);
 }