Rename PatternArtifactFilterTCK to AbstractPatternArtifactFilterTest and let TCK users extend it to ensure that always all tests are called.

git-svn-id: https://svn.apache.org/repos/asf/maven/shared/trunk@1694098 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/src/test/java/org/apache/maven/shared/artifact/filter/PatternArtifactFilterTCK.java b/src/test/java/org/apache/maven/shared/artifact/filter/AbstractPatternArtifactFilterTest.java
similarity index 99%
rename from src/test/java/org/apache/maven/shared/artifact/filter/PatternArtifactFilterTCK.java
rename to src/test/java/org/apache/maven/shared/artifact/filter/AbstractPatternArtifactFilterTest.java
index 3e9f8fc..c420180 100644
--- a/src/test/java/org/apache/maven/shared/artifact/filter/PatternArtifactFilterTCK.java
+++ b/src/test/java/org/apache/maven/shared/artifact/filter/AbstractPatternArtifactFilterTest.java
@@ -31,7 +31,7 @@
 
 import static org.easymock.EasyMock.*;
 
-public abstract class PatternArtifactFilterTCK
+public abstract class AbstractPatternArtifactFilterTest
     extends TestCase
 {
 
diff --git a/src/test/java/org/apache/maven/shared/artifact/filter/PatternExcludesArtifactFilterTest.java b/src/test/java/org/apache/maven/shared/artifact/filter/PatternExcludesArtifactFilterTest.java
index a7db2a1..00ad6ca 100644
--- a/src/test/java/org/apache/maven/shared/artifact/filter/PatternExcludesArtifactFilterTest.java
+++ b/src/test/java/org/apache/maven/shared/artifact/filter/PatternExcludesArtifactFilterTest.java
@@ -21,155 +21,28 @@
 
 import java.util.List;
 
-import junit.framework.TestCase;
-
 import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
 
 public class PatternExcludesArtifactFilterTest
-    extends TestCase
+    extends AbstractPatternArtifactFilterTest
 {
 
-    private final PatternArtifactFilterTCK tck = new PatternArtifactFilterTCK()
+    @Override
+    protected ArtifactFilter createFilter( final List<String> patterns )
     {
-
-        @Override
-        protected ArtifactFilter createFilter( final List<String> patterns )
-        {
-            return new PatternExcludesArtifactFilter( patterns );
-        }
-
-        @Override
-        protected ArtifactFilter createFilter( final List<String> patterns, final boolean actTransitively )
-        {
-            return new PatternExcludesArtifactFilter( patterns, actTransitively );
-        }
-
-        @Override
-        protected boolean isInclusionExpected()
-        {
-            return false;
-        }
-
-    };
-
-    public void testShouldTriggerBothPatternsWithNonColonWildcards()
-    {
-        tck.testShouldTriggerBothPatternsWithNonColonWildcards();
+        return new PatternExcludesArtifactFilter( patterns );
     }
 
-    public void testIncludeWhenPatternMatchesDepTrailWithTransitivityUsingNonColonWildcard()
+    @Override
+    protected ArtifactFilter createFilter( final List<String> patterns, final boolean actTransitively )
     {
-        tck.testIncludeWhenPatternMatchesDepTrailWithTransitivityUsingNonColonWildcard();
+        return new PatternExcludesArtifactFilter( patterns, actTransitively );
     }
 
-    public void testShouldTriggerBothPatternsWithWildcards()
+    @Override
+    protected boolean isInclusionExpected()
     {
-        tck.testShouldTriggerBothPatternsWithWildcards();
+        return false;
     }
 
-    public void testShouldNotIncludeDirectlyMatchedArtifactByDependencyConflictId()
-    {
-        tck.testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId();
-    }
-
-    public void testShouldNotIncludeDirectlyMatchedArtifactByGroupIdArtifactId()
-    {
-        tck.testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId();
-    }
-
-    public void testShouldNotIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled()
-    {
-        tck.testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled();
-    }
-
-    public void testShouldIncludeWhenArtifactIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenArtifactIdDiffers();
-    }
-
-    public void testShouldIncludeWhenBothIdElementsDiffer()
-    {
-        tck.testShouldNotIncludeWhenBothIdElementsDiffer();
-    }
-
-    public void testShouldIncludeWhenGroupIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenGroupIdDiffers();
-    }
-
-    public void testShouldIncludeWhenNegativeMatch()
-    {
-        tck.testShouldNotIncludeWhenNegativeMatch();
-    }
-
-    public void testShouldNotIncludeWhenWildcardMatchesInsideSequence()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesInsideSequence();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesOutsideSequence()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesOutsideSequence();
-    }
-
-    public void testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent()
-    {
-        tck.testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesMiddleOfArtifactId()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesMiddleOfArtifactId();
-    }
-
-    public void testShouldIncludeWhenWildcardCoversPartOfGroupIdAndEverythingElse()
-    {
-        tck.testShouldIncludeWhenWildcardCoversPartOfGroupIdAndEverythingElse();
-    }
-
-    public void testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId()
-    {
-        tck.testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId();
-    }
-
-    public void testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId()
-    {
-        tck.testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId();
-    }
-
-    public void testShouldNotIncludeWhenGroupIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenGroupIdDiffers();
-    }
-
-    public void testShouldNotIncludeWhenArtifactIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenArtifactIdDiffers();
-    }
-
-    public void testShouldNotIncludeWhenBothIdElementsDiffer()
-    {
-        tck.testShouldNotIncludeWhenBothIdElementsDiffer();
-    }
-
-    public void testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled()
-    {
-        tck.testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled();
-    }
-
-    public void testShouldNotIncludeWhenNegativeMatch()
-    {
-        tck.testShouldNotIncludeWhenNegativeMatch();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesInsideSequence()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesInsideSequence();
-    }
-
-    // See comment in TCK.
-    // public void testShouldIncludeDirectDependencyWhenInvertedWildcardMatchesButDoesntMatchTransitiveChild()
-    // {
-    // tck.testShouldIncludeDirectDependencyWhenInvertedWildcardMatchesButDoesntMatchTransitiveChild();
-    // }
 }
diff --git a/src/test/java/org/apache/maven/shared/artifact/filter/PatternIncludesArtifactFilterTest.java b/src/test/java/org/apache/maven/shared/artifact/filter/PatternIncludesArtifactFilterTest.java
index 98c70d6..5fcb905 100644
--- a/src/test/java/org/apache/maven/shared/artifact/filter/PatternIncludesArtifactFilterTest.java
+++ b/src/test/java/org/apache/maven/shared/artifact/filter/PatternIncludesArtifactFilterTest.java
@@ -21,114 +21,26 @@
 
 import java.util.List;
 
-import junit.framework.TestCase;
-
 import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
 
 public class PatternIncludesArtifactFilterTest
-    extends TestCase
+    extends AbstractPatternArtifactFilterTest
 {
-    private final PatternArtifactFilterTCK tck = new PatternArtifactFilterTCK()
+    @Override
+    protected ArtifactFilter createFilter( final List<String> patterns )
     {
-
-        @Override
-        protected ArtifactFilter createFilter( final List<String> patterns )
-        {
-            return new PatternIncludesArtifactFilter( patterns );
-        }
-
-        @Override
-        protected ArtifactFilter createFilter( final List<String> patterns, final boolean actTransitively )
-        {
-            return new PatternIncludesArtifactFilter( patterns, actTransitively );
-        }
-
-        @Override
-        protected boolean isInclusionExpected()
-        {
-            return true;
-        }
-
-    };
-
-    public void testShouldTriggerBothPatternsWithNonColonWildcards()
-    {
-        tck.testShouldTriggerBothPatternsWithNonColonWildcards();
+        return new PatternIncludesArtifactFilter( patterns );
     }
 
-    public void testShouldTriggerBothPatternsWithWildcards()
+    @Override
+    protected ArtifactFilter createFilter( final List<String> patterns, final boolean actTransitively )
     {
-        tck.testShouldTriggerBothPatternsWithWildcards();
+        return new PatternIncludesArtifactFilter( patterns, actTransitively );
     }
 
-    public void testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId()
+    @Override
+    protected boolean isInclusionExpected()
     {
-        tck.testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId();
+        return true;
     }
-
-    public void testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId()
-    {
-        tck.testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId();
-    }
-
-    public void testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled()
-    {
-        tck.testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled();
-    }
-
-    public void testIncludeWhenPatternMatchesDepTrailWithTransitivityUsingNonColonWildcard()
-    {
-        tck.testIncludeWhenPatternMatchesDepTrailWithTransitivityUsingNonColonWildcard();
-    }
-
-    public void testShouldNotIncludeWhenArtifactIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenArtifactIdDiffers();
-    }
-
-    public void testShouldNotIncludeWhenBothIdElementsDiffer()
-    {
-        tck.testShouldNotIncludeWhenBothIdElementsDiffer();
-    }
-
-    public void testShouldNotIncludeWhenGroupIdDiffers()
-    {
-        tck.testShouldNotIncludeWhenGroupIdDiffers();
-    }
-
-    public void testShouldNotIncludeWhenNegativeMatch()
-    {
-        tck.testShouldNotIncludeWhenNegativeMatch();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesInsideSequence()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesInsideSequence();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesOutsideSequence()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesOutsideSequence();
-    }
-
-    public void testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent()
-    {
-        tck.testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent();
-    }
-
-    public void testShouldIncludeWhenWildcardMatchesMiddleOfArtifactId()
-    {
-        tck.testShouldIncludeWhenWildcardMatchesMiddleOfArtifactId();
-    }
-
-    public void testShouldIncludeWhenWildcardCoversPartOfGroupIdAndEverythingElse()
-    {
-        tck.testShouldIncludeWhenWildcardCoversPartOfGroupIdAndEverythingElse();
-    }
-
-    // See comment in TCK.
-    // public void testShouldIncludeDirectDependencyWhenInvertedWildcardMatchesButDoesntMatchTransitiveChild()
-    // {
-    // tck.testShouldIncludeDirectDependencyWhenInvertedWildcardMatchesButDoesntMatchTransitiveChild();
-    // }
 }