This is an automated email from the ASF dual-hosted git repository. clebertsuconic pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git
commit 45a4f6fc39f6aebdf27778fc1a7e1132842cd36b Author: Clebert Suconic <[email protected]> AuthorDate: Fri Apr 17 16:32:13 2020 -0400 ARTEMIS-2720 Additional test I wrote a small / quick test while I was testing the PR #3089 and I decided to keep it with the PR --- .../activemq/artemis/core/settings/RepositoryTest.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/artemis-server/src/test/java/org/apache/activemq/artemis/core/settings/RepositoryTest.java b/artemis-server/src/test/java/org/apache/activemq/artemis/core/settings/RepositoryTest.java index bdcd493..7770472 100644 --- a/artemis-server/src/test/java/org/apache/activemq/artemis/core/settings/RepositoryTest.java +++ b/artemis-server/src/test/java/org/apache/activemq/artemis/core/settings/RepositoryTest.java @@ -66,6 +66,18 @@ public class RepositoryTest extends ActiveMQTestBase { } @Test + public void testCacheWithWildcards() throws Throwable { + HierarchicalObjectRepository<String> repo = new HierarchicalObjectRepository<>(); + + repo.addMatch("#", "root"); + Assert.assertEquals("root", repo.getMatch("b")); + + repo.addMatch("b", "leaf"); + Assert.assertEquals("leaf", repo.getMatch("b")); + } + + + @Test public void testMatchingDocsCustomUnderscorDelimiter() throws Throwable { WildcardConfiguration wildcardConfiguration = new WildcardConfiguration(); wildcardConfiguration.setDelimiter('_');
