diff options
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r-- | sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java b/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java index 98396d0e4a5..16ece8c3704 100644 --- a/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java +++ b/sonar-plugin-api/src/test/java/org/sonar/api/utils/WildcardPatternTest.java @@ -19,13 +19,14 @@ */ package org.sonar.api.utils; -import org.junit.Test; - import static org.hamcrest.CoreMatchers.is; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertThat; import static org.junit.Assert.assertTrue; +import org.junit.Ignore; +import org.junit.Test; + public class WildcardPatternTest { private boolean match(String pattern, String value, String separator) { @@ -102,6 +103,19 @@ public class WildcardPatternTest { assertTrue(match("**", "java/io/Reader")); } + /** + * See http://jira.codehaus.org/browse/SONAR-2193 + */ + @Ignore + @Test + public void issue2193() { + assertTrue(match("**/app/**", "com.app.Utils", ".")); + assertFalse(match("**/app/**", "com.application.MyService", ".")); + + assertTrue(match("**/app/**", "com/app/Utils")); + assertFalse(match("**/app/**", "com/application/MyService")); + } + @Test public void multiplePatterns() { WildcardPattern[] patterns = new WildcardPattern[] { WildcardPattern.create("Foo"), WildcardPattern.create("Bar") }; |