Skip to content

Commit 214995e

Browse files
andrzejj0slawekjaranowski
authored andcommitted
Fix for issue #648: de-shadowing the localRepository property
1 parent 751ace7 commit 214995e

File tree

4 files changed

+51
-6
lines changed

4 files changed

+51
-6
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
invoker.goals.1=${project.groupId}:${project.artifactId}:${project.version}:dependency-updates-report
2+
3+
invoker.goals.2=${project.groupId}:${project.artifactId}:${project.version}:plugin-updates-report
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
3+
<modelVersion>4.0.0</modelVersion>
4+
<groupId>localhost</groupId>
5+
<artifactId>it-abstract-versions-report-001</artifactId>
6+
<version>1.0</version>
7+
<packaging>pom</packaging>
8+
<name>abstract-versions-report</name>
9+
<url>http://localhost/</url>
10+
11+
<description>
12+
Testing command line invocation of dependency- and plugin-updates-report
13+
</description>
14+
15+
<dependencies>
16+
<dependency>
17+
<groupId>localhost</groupId>
18+
<artifactId>dummy-api</artifactId>
19+
<version>1.1</version>
20+
</dependency>
21+
</dependencies>
22+
23+
<build>
24+
<plugins>
25+
<plugin>
26+
<groupId>localhost</groupId>
27+
<artifactId>dummy-maven-plugin</artifactId>
28+
<version>1.0</version>
29+
</plugin>
30+
</plugins>
31+
</build>
32+
33+
</project>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
dependencyUpdatesReport = new File( basedir, "target/site/dependency-updates-report.html" )
2+
3+
assert dependencyUpdatesReport.exists( )
4+
5+
// some basic (=not comprehensive) checks on the contents of the dependency report
6+
assert dependencyUpdatesReport.text =~ /\b1\.1\.0-2\b/ // current version of the dependency
7+
assert dependencyUpdatesReport.text =~ /\b3\.0\b/ // latest major available version
8+
9+
pluginUpdatesReport = new File( basedir, "target/site/plugin-updates-report.html" )
10+
11+
assert pluginUpdatesReport.exists( )
12+
13+
// some basic (=not comprehensive) checks on the contents of the plugin report
14+
assert pluginUpdatesReport.text =~ /\b1\.0\b/ // current version of the plugin
15+
assert pluginUpdatesReport.text =~ /\b3\.1\b/ // latest major available version

src/main/java/org/codehaus/mojo/versions/AbstractVersionsReport.java

-6
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,6 @@ public abstract class AbstractVersionsReport
102102
@Parameter( defaultValue = "${project.pluginArtifactRepositories}", readonly = true )
103103
protected List<ArtifactRepository> remotePluginRepositories;
104104

105-
/**
106-
* @since 1.0-alpha-1
107-
*/
108-
@Parameter( defaultValue = "${localRepository}", readonly = true )
109-
protected ArtifactRepository localRepository;
110-
111105
/**
112106
* @since 1.0-alpha-3
113107
*/

0 commit comments

Comments
 (0)