1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.maven.shared.artifact.filter;
20
21 import java.util.List;
22
23 import junit.framework.TestCase;
24
25 import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
26
27 public class PatternExcludesArtifactFilterTest
28 extends TestCase
29 {
30
31 private PatternArtifactFilterTCK tck = new PatternArtifactFilterTCK()
32 {
33
34 protected ArtifactFilter createFilter( List patterns )
35 {
36 return new PatternExcludesArtifactFilter( patterns );
37 }
38
39 protected ArtifactFilter createFilter( List patterns, boolean actTransitively )
40 {
41 return new PatternExcludesArtifactFilter( patterns, actTransitively );
42 }
43
44 };
45
46 public void testShouldTriggerBothPatternsWithWildcards()
47 {
48 tck.testShouldTriggerBothPatternsWithWildcards( true );
49 }
50
51 public void testShouldNotIncludeDirectlyMatchedArtifactByDependencyConflictId()
52 {
53 tck.testShouldIncludeDirectlyMatchedArtifactByDependencyConflictId( true );
54 }
55
56 public void testShouldNotIncludeDirectlyMatchedArtifactByGroupIdArtifactId()
57 {
58 tck.testShouldIncludeDirectlyMatchedArtifactByGroupIdArtifactId( true );
59 }
60
61 public void testShouldNotIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled()
62 {
63 tck.testShouldIncludeWhenPatternMatchesDependencyTrailAndTransitivityIsEnabled( true );
64 }
65
66 public void testShouldIncludeWhenArtifactIdDiffers()
67 {
68 tck.testShouldNotIncludeWhenArtifactIdDiffers( true );
69 }
70
71 public void testShouldIncludeWhenBothIdElementsDiffer()
72 {
73 tck.testShouldNotIncludeWhenBothIdElementsDiffer( true );
74 }
75
76 public void testShouldIncludeWhenGroupIdDiffers()
77 {
78 tck.testShouldNotIncludeWhenGroupIdDiffers( true );
79 }
80
81 public void testShouldIncludeWhenNegativeMatch()
82 {
83 tck.testShouldNotIncludeWhenNegativeMatch( true );
84 }
85
86 public void testShouldNotIncludeWhenWildcardMatchesInsideSequence()
87 {
88 tck.testShouldIncludeWhenWildcardMatchesInsideSequence( true );
89 }
90
91 public void testShouldIncludeWhenWildcardMatchesOutsideSequence()
92 {
93 tck.testShouldIncludeWhenWildcardMatchesOutsideSequence( true );
94 }
95
96 public void testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent()
97 {
98 tck.testShouldIncludeTransitiveDependencyWhenWildcardMatchesButDoesntMatchParent( true );
99 }
100
101
102
103
104
105
106 }