public void Test_LoadConfigurationForFile()
        {
            var filePath = CreateConfigFile("config.json",
              new JObject(
                  new JProperty("SomeKey", "SomeValue")));

            var directory = new Directory(null, "dir");

            var fileMock = MockFile("file.ext", "", directory);
            directory.AddFile(fileMock.Object);

            var configFileMock = MockFile("file.ext.MusicFileCop.json", filePath, directory);            
            directory.AddFile(configFileMock.Object);
                      
            var mapper = new ConfigurationMapper();

            var configurationLoader = new ConfigurationLoader(mapper, MockDefaultConfigurationNode().Object);
            configurationLoader.LoadConfiguration(MockConfigurationNode().Object, fileMock.Object);

            var config = mapper.GetConfiguration(fileMock.Object);
            Assert.NotNull(config);

            Assert.Equal("SomeValue", config.GetValue("SomeKey"));
            

        }
        public void Test_LoadConfigurationFile()
        {
            var filePath = CreateConfigFile("config.json",
                new JObject(
                    new JProperty("SomeKey", "SomeValue"),
                    new JProperty("SomeKey1",
                        new JObject(new JProperty("SubKey", "SomeOtherValue")))));

            var fileMock = MockFile("Irrelevant", filePath, null);
            
            var configurationLoader = new ConfigurationLoader(new ConfigurationMapper(), MockDefaultConfigurationNode().Object);
            var configNode = configurationLoader.LoadConfigurationFile(fileMock.Object);

            Assert.Equal("SomeValue", configNode.Get("SomeKey"));
            Assert.Equal("SomeOtherValue", configNode.Get("SomeKey1:SubKey"));

            
        }
        public void Test_FileInheritsDirectoryConfiguration()
        {
            var directoryConfig = CreateConfigFile("config1.json",
             new JObject(
                 new JProperty("SomeKey", "SomeValue")));
            
            var directory = new Directory(null, "Irrelevant");

            var directoryConfigMock = MockFile("MusicFileCop.json", directoryConfig, directory);
            var fileMock = MockFile("file1.ext", "", directory);

            directory.AddFile(directoryConfigMock.Object);
            directory.AddFile(fileMock.Object);

            
            var mapper = new ConfigurationMapper();
                       
            var configurationLoader = new ConfigurationLoader(mapper, MockDefaultConfigurationNode().Object);
            configurationLoader.LoadConfiguration(MockConfigurationNode().Object, directory);

            var fileConfig = mapper.GetConfiguration(fileMock.Object);

            Assert.NotNull(fileConfig);
            Assert.Equal("SomeValue", fileConfig.GetValue("SomeKey"));            
        }