public void testMergeConfigurations() throws Exception {
Configuration one = new BaseConfiguration();
one.setProperty("foo", "bar");
PropertiesConfiguration two = new PropertiesConfiguration();
String properties = "## some header \n" + "foo = bar1\n" + "bar = foo\n";
two.load(new StringReader(properties));
configurationFactory.setConfigurations(new Configuration[] { one, two });
configurationFactory.afterPropertiesSet();
Properties props = (Properties) configurationFactory.getObject();
assertEquals("foo", props.getProperty("bar"));