mirror of https://github.com/apache/maven.git
o Made IT check plugin config via model inspection for 3.x which provides an effective model including plugin config
git-svn-id: https://svn.apache.org/repos/asf/maven/core-integration-testing/trunk@797437 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
c12ee05a1e
commit
bd8f381431
|
@ -90,8 +90,18 @@ public class MavenITmng0469ReportConfigTest
|
|||
Verifier verifier = new Verifier( testDir.getAbsolutePath() );
|
||||
verifier.deleteDirectory( "target" );
|
||||
verifier.setAutoclean( false );
|
||||
verifier.executeGoal( "org.apache.maven.its.plugins:maven-it-plugin-site:2.1-SNAPSHOT:generate" );
|
||||
verifier.assertFilePresent( "target/site/info.properties" );
|
||||
if ( matchesVersionRange( "(,3.0-alpha-1)" ) )
|
||||
{
|
||||
verifier.executeGoal( "org.apache.maven.its.plugins:maven-it-plugin-site:2.1-SNAPSHOT:generate" );
|
||||
verifier.assertFilePresent( "target/site/info.properties" );
|
||||
}
|
||||
else
|
||||
{
|
||||
verifier.executeGoal( "validate" );
|
||||
Properties props = verifier.loadProperties( "target/config.properties" );
|
||||
assertEquals( "maven-it-plugin-site", props.getProperty( "project.reporting.plugins.0.artifactId" ) );
|
||||
assertFalse( "fail.properties".equals( props.getProperty( "project.reporting.plugins.0.configuration.children.infoFile.0.value" ) ) );
|
||||
}
|
||||
verifier.verifyErrorFreeLog();
|
||||
verifier.resetStreams();
|
||||
}
|
||||
|
|
|
@ -43,6 +43,26 @@ under the License.
|
|||
<infoFile>fail.properties</infoFile>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.its.plugins</groupId>
|
||||
<artifactId>maven-it-plugin-expression</artifactId>
|
||||
<version>2.1-SNAPSHOT</version>
|
||||
<configuration>
|
||||
<outputFile>target/config.properties</outputFile>
|
||||
<expressions>
|
||||
<expression>project/build/plugins/8/configuration</expression>
|
||||
</expressions>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>test</id>
|
||||
<phase>validate</phase>
|
||||
<goals>
|
||||
<goal>eval</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
|
|
Loading…
Reference in New Issue