HibernateConfiguration extends AbstractConfiguration implements Configuration { @Override public boolean containsKey(final String key) { return getConfiguration().containsKey(key); } HibernateConfiguration(final SessionFactory factory,
                                  final String section); @Override boolean isEmpty(); @Override boolean containsKey(final String key); @Override Object getProperty(final String key); @Override void clear(); @Override Iterator<String> getKeys();  }
@Test public void testStoreAndRetrieve() { configOne.addProperty("key", "value"); assertTrue(configOne.containsKey("key")); assertEquals("value", configOne.getString("key")); configOne.clearProperty("key"); assertFalse(configOne.containsKey("key")); }
@Test public void testMultipleInstances() { configOne.addProperty("key", "value"); assertTrue(configOne.containsKey("key")); Configuration configuration = new HibernateConfiguration( getSessionFactory(), "one"); assertTrue(configuration.containsKey("key")); }
@Test public void testNoGroupConflict() { configOne.addProperty("key", "value"); assertTrue(configOne.containsKey("key")); assertFalse(configTwo.containsKey("key")); configTwo.addProperty("foo", "bar"); assertFalse(configOne.containsKey("foo")); assertTrue(configTwo.containsKey("foo")); }