AbstractHierarchicalConfiguration.getKeys(key) doesn't return the key
---------------------------------------------------------------------

                 Key: CONFIGURATION-321
                 URL: https://issues.apache.org/jira/browse/CONFIGURATION-321
             Project: Commons Configuration
          Issue Type: Bug
    Affects Versions: 1.5
            Reporter: Emmanuel Bourg
             Fix For: 1.6


The getKeys(String prefix) implementation of AbstractHierarchicalConfiguration 
doesn't return anything if the prefix used is the key of an existing property. 
The iterator returned should at least contain the key used as the prefix.

Here is the test method for TestHierarchicalConfiguration, currently the first 
assertion fails:

{code:java}
public void testGetKeysWithKeyAsPrefix()
{
    Iterator<?> it = config.getKeys("order.key1");
    assertTrue("no key found", it.hasNext());
    assertEquals("1st key", "order.key1", it.next());
    assertFalse("more keys than expected", it.hasNext());
}
{code}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to