From 5265bc6bb49a13db03bcc4a19416c3c5a93acf89 Mon Sep 17 00:00:00 2001 From: Benjamin Bentmann Date: Sat, 13 Jun 2009 15:09:19 +0000 Subject: [PATCH] o Updated IT for 3.x which keeps the original dependeny type such that reactor resolution is transparent to clients git-svn-id: https://svn.apache.org/repos/asf/maven/core-integration-testing/trunk@784406 13f79535-47bb-0310-9956-ffa450edef68 --- ...fierBasedDepResolutionFromReactorTest.java | 34 ++++++++++++++----- 1 file changed, 26 insertions(+), 8 deletions(-) diff --git a/its/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4056ClassifierBasedDepResolutionFromReactorTest.java b/its/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4056ClassifierBasedDepResolutionFromReactorTest.java index 1ee2f9ad1c..9b23808a72 100644 --- a/its/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4056ClassifierBasedDepResolutionFromReactorTest.java +++ b/its/core-it-suite/src/test/java/org/apache/maven/it/MavenITmng4056ClassifierBasedDepResolutionFromReactorTest.java @@ -57,14 +57,32 @@ public class MavenITmng4056ClassifierBasedDepResolutionFromReactorTest verifier.resetStreams(); List artifacts = verifier.loadLines( "consumer/target/artifacts.txt", "UTF-8" ); - assertTrue( artifacts.toString(), - artifacts.contains( "org.apache.maven.its.mng4056:producer:test-jar:tests:0.1" ) ); - assertTrue( artifacts.toString(), - artifacts.contains( "org.apache.maven.its.mng4056:producer:java-source:sources:0.1" ) ); - assertTrue( artifacts.toString(), - artifacts.contains( "org.apache.maven.its.mng4056:producer:javadoc:javadoc:0.1" ) ); - assertTrue( artifacts.toString(), - artifacts.contains( "org.apache.maven.its.mng4056:producer:ejb-client:client:0.1" ) ); + if ( matchesVersionRange( "[3.0-alpha-3,)" ) ) + { + // artifact type unchanged to match type as declared in dependency + + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:jar:tests:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:jar:sources:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:jar:javadoc:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:jar:client:0.1" ) ); + } + else + { + // artifact type updated to match type of active artifact + + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:test-jar:tests:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:java-source:sources:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:javadoc:javadoc:0.1" ) ); + assertTrue( artifacts.toString(), + artifacts.contains( "org.apache.maven.its.mng4056:producer:ejb-client:client:0.1" ) ); + } List classpath = verifier.loadLines( "consumer/target/compile.txt", "UTF-8" ); assertTrue( classpath.toString(), classpath.contains( "producer/test.jar" ) );