use of com.thoughtworks.go.config.merge.MergeConfigOrigin in project gocd by gocd.
the class MagicalGoConfigXmlLoaderTest method shouldSetConfigOriginInCruiseConfig_AfterLoadingConfigFile.
@Test
public void shouldSetConfigOriginInCruiseConfig_AfterLoadingConfigFile() throws Exception {
GoConfigHolder goConfigHolder = xmlLoader.loadConfigHolder(CONFIG, new MagicalGoConfigXmlLoader.Callback() {
@Override
public void call(CruiseConfig cruiseConfig) {
cruiseConfig.setPartials(asList(new PartialConfig()));
}
});
assertThat(goConfigHolder.config.getOrigin(), Is.<ConfigOrigin>is(new MergeConfigOrigin()));
assertThat(goConfigHolder.configForEdit.getOrigin(), Is.<ConfigOrigin>is(new FileConfigOrigin()));
}
Aggregations