mirror of https://github.com/apache/maven.git
[MNG-4845] [regression] MavenProject.getDependencyArtifact() returns artifacts without version for dependency with version range
o Extended relevant IT git-svn-id: https://svn.apache.org/repos/asf/maven/core-integration-testing/trunk@1003535 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e97ca06de4
commit
5f8a0dbf6c
|
@ -26,7 +26,8 @@ import java.io.File;
|
|||
import java.util.Properties;
|
||||
|
||||
/**
|
||||
* This is a test set for <a href="http://jira.codehaus.org/browse/MNG-4750">MNG-4750</a>.
|
||||
* This is a test set for <a href="http://jira.codehaus.org/browse/MNG-4750">MNG-4750</a> and
|
||||
* <a href="http://jira.codehaus.org/browse/MNG-4845">MNG-4845</a>.
|
||||
*
|
||||
* @author Benjamin Bentmann
|
||||
*/
|
||||
|
@ -36,7 +37,7 @@ public class MavenITmng4750ResolvedMavenProjectDependencyArtifactsTest
|
|||
|
||||
public MavenITmng4750ResolvedMavenProjectDependencyArtifactsTest()
|
||||
{
|
||||
super( "[2.0.3,3.0-alpha-1),[3.0-alpha-3,)" );
|
||||
super( "[2.0.3,3.0-alpha-1),[3.0,)" );
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -64,6 +65,9 @@ public class MavenITmng4750ResolvedMavenProjectDependencyArtifactsTest
|
|||
String path = props.getProperty( "project.dependencyArtifacts.0.file" );
|
||||
assertNotNull( path );
|
||||
assertTrue( path, new File( path ).isFile() );
|
||||
|
||||
String version = props.getProperty( "project.dependencyArtifacts.0.version" );
|
||||
assertEquals( "0.1", version );
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -37,7 +37,8 @@ under the License.
|
|||
<dependency>
|
||||
<groupId>org.apache.maven.its.mng4750</groupId>
|
||||
<artifactId>a</artifactId>
|
||||
<version>0.1</version>
|
||||
<!-- NOTE: This intentionally uses a version range -->
|
||||
<version>(,0.1]</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
@ -71,6 +72,7 @@ under the License.
|
|||
<expressions>
|
||||
<expression>project/dependencyArtifacts/size</expression>
|
||||
<expression>project/dependencyArtifacts/*/file</expression>
|
||||
<expression>project/dependencyArtifacts/*/version</expression>
|
||||
</expressions>
|
||||
</configuration>
|
||||
<executions>
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<metadata>
|
||||
<groupId>org.apache.maven.its.mng4750</groupId>
|
||||
<artifactId>a</artifactId>
|
||||
<versioning>
|
||||
<latest>0.1</latest>
|
||||
<release>0.1</release>
|
||||
<versions>
|
||||
<version>0.1</version>
|
||||
</versions>
|
||||
<lastUpdated>20100909120034</lastUpdated>
|
||||
</versioning>
|
||||
</metadata>
|
Loading…
Reference in New Issue