File tree Expand file tree Collapse file tree 4 files changed +12
-31
lines changed
it/projects/analyze-testDependencyWithNonTestScope
main/java/org/apache/maven/plugins/dependency Expand file tree Collapse file tree 4 files changed +12
-31
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ under the License.
28
28
</parent >
29
29
30
30
<artifactId >maven-dependency-plugin</artifactId >
31
- <version >3.6.2 -SNAPSHOT</version >
31
+ <version >3.7.0 -SNAPSHOT</version >
32
32
<packaging >maven-plugin</packaging >
33
33
34
34
<name >Apache Maven Dependency Plugin</name >
@@ -165,33 +165,23 @@ under the License.
165
165
<scope >provided</scope >
166
166
</dependency >
167
167
168
- <!-- reporting -->
168
+ <!-- doxia -->
169
169
<dependency >
170
170
<groupId >org.apache.maven.doxia</groupId >
171
171
<artifactId >doxia-sink-api</artifactId >
172
- <version >1.11.1</version >
173
- <exclusions >
174
- <exclusion >
175
- <groupId >org.codehaus.plexus</groupId >
176
- <artifactId >plexus-container-default</artifactId >
177
- </exclusion >
178
- </exclusions >
172
+ <version >2.0.0-M8</version >
179
173
</dependency >
174
+
175
+ <!-- reporting -->
180
176
<dependency >
181
177
<groupId >org.apache.maven.reporting</groupId >
182
178
<artifactId >maven-reporting-api</artifactId >
183
- <version >3.1.1 </version >
179
+ <version >4.0.0-M8 </version >
184
180
</dependency >
185
181
<dependency >
186
182
<groupId >org.apache.maven.reporting</groupId >
187
183
<artifactId >maven-reporting-impl</artifactId >
188
- <version >3.2.0</version >
189
- <exclusions >
190
- <exclusion >
191
- <groupId >org.codehaus.plexus</groupId >
192
- <artifactId >plexus-container-default</artifactId >
193
- </exclusion >
194
- </exclusions >
184
+ <version >4.0.0-M11</version >
195
185
</dependency >
196
186
<dependency >
197
187
<groupId >commons-io</groupId >
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ if ( htmlFile.length() == 0 )
37
37
38
38
Document doc = Jsoup.parse( htmlFile, "UTF-8");
39
39
40
- Elements entry = doc.select( "#contentBox > section > section:nth-child(5) > table > tbody > tr.b" );
40
+ Elements entry = doc.select( "#bodyColumn > section > section:nth-child(5) > table > tbody > tr.b" );
41
41
42
42
if( entry.isEmpty() )
43
43
{
@@ -50,7 +50,7 @@ else if ( entry.size() != 1 )
50
50
}
51
51
52
52
Element groupIdElement = doc.select(
53
- "#contentBox > section > section:nth-child(5) > table > tbody > tr.b > td:nth-child(1)" ).first();
53
+ "#bodyColumn > section > section:nth-child(5) > table > tbody > tr.b > td:nth-child(1)" ).first();
54
54
55
55
String groupId = groupIdElement.text();
56
56
Original file line number Diff line number Diff line change 20
20
21
21
import java .util .ArrayList ;
22
22
import java .util .List ;
23
- import java .util .Locale ;
24
23
25
24
import org .apache .maven .plugin .AbstractMojo ;
26
25
import org .apache .maven .plugin .MojoExecutionException ;
@@ -62,14 +61,8 @@ private ArrayList<String> collectAncestors() {
62
61
63
62
MavenProject currentAncestor = project .getParent ();
64
63
while (currentAncestor != null ) {
65
- final String gav = String .format (
66
- Locale .US ,
67
- "%s:%s:%s" ,
68
- currentAncestor .getGroupId (),
69
- currentAncestor .getArtifactId (),
70
- currentAncestor .getVersion ());
71
-
72
- ancestors .add (gav );
64
+ ancestors .add (currentAncestor .getGroupId () + ":" + currentAncestor .getArtifactId () + ":"
65
+ + currentAncestor .getVersion ());
73
66
74
67
currentAncestor = currentAncestor .getParent ();
75
68
}
Original file line number Diff line number Diff line change 41
41
*/
42
42
@ Mojo (name = "analyze-report" , requiresDependencyResolution = ResolutionScope .TEST , threadSafe = true )
43
43
@ Execute (phase = LifecyclePhase .TEST_COMPILE )
44
- public class AnalyzeReportMojo extends AbstractMavenReport {
44
+ public class AnalyzeReport extends AbstractMavenReport {
45
45
// fields -----------------------------------------------------------------
46
46
47
47
/**
@@ -115,13 +115,11 @@ public void executeReport(Locale locale) throws MavenReportException {
115
115
@ Override
116
116
public boolean canGenerateReport () {
117
117
if (skip ) {
118
- getLog ().info ("Skipping plugin execution" );
119
118
return false ;
120
119
}
121
120
122
121
// Step 0: Checking pom availability
123
122
if ("pom" .equals (project .getPackaging ())) {
124
- getLog ().info ("Skipping pom project" );
125
123
return false ;
126
124
}
127
125
You can’t perform that action at this time.
0 commit comments