Package org.apache.maven.it

Examples of org.apache.maven.it.Verifier


    public OutputValidator getSubProjectValidator( String subProject )
        throws VerificationException
    {
        final File subFile = getValidator().getSubFile( subProject );
        return new OutputValidator( new Verifier( subFile.getAbsolutePath() ) );
    }
View Full Code Here


    {
        if ( verifier == null )
        {
            try
            {
                this.verifier = new Verifier( ensureUnpacked().getAbsolutePath() );
            }
            catch ( VerificationException e )
            {
                throw new RuntimeException( e );
            }
View Full Code Here

   
    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "generate-from-override" );
        Verifier verifier = new Verifier( dir.getAbsolutePath() );
       
        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();
       
        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );
       
        assertTrue( content.indexOf( "Override:" ) > -1 );
View Full Code Here

    @SuppressWarnings( "unchecked" )
    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "custom-filter-delim" );
        Verifier verifier = new Verifier( dir.getAbsolutePath() );
       
        verifier.getCliOptions().add( "-X" );
       
        verifier.executeGoal( "validate" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();
       
        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );
       
        assertTrue( content.indexOf( "Override: custom-filter-delim" ) > -1 );
View Full Code Here

    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "get-dependency-projects" );

        Verifier verifier;

        verifier = new Verifier( dir.getAbsolutePath() );
        verifier.executeGoal( "deploy" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        verifier = new Verifier( new File( dir, "project" ).getAbsolutePath() );

        verifier.deleteArtifacts( "org.apache.maven.plugin.rresource.it.gdp" );

        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        File output = new File( dir, "project/target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );

        assertTrue( content.indexOf( "Dependency Id: org.apache.maven.plugin.rresource.it.gdp:release:1.0" ) >= 0 );
View Full Code Here

    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "bad-dependency-poms" );

        Verifier verifier;

        verifier = new Verifier( dir.getAbsolutePath() );
        verifier.deleteArtifacts( "test" );
        verifier.getSystemProperties().setProperty( "it.dir", dir.getAbsolutePath() );
        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );

        assertTrue( content.indexOf( "Dependency Id: test:missing:0.1" ) >= 0 );
View Full Code Here

        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "supplemental-artifact" );
        File resources = new File( dir, "resource-projects" );

        Verifier verifier;

        verifier = new Verifier( resources.getAbsolutePath() );
       
        verifier.deleteArtifacts( "org.apache.maven.plugin.rresource.it.mrr43" );

        verifier.executeGoal( "deploy" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        verifier = new Verifier( dir.getAbsolutePath() );

        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );
       
        assertTrue( content.indexOf( "From: 'Deficient Tooling, Inc.' (http://www.deficient-tools.us/)" ) > -1 );
View Full Code Here

   
    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "filter-local-override" );
        Verifier verifier = new Verifier( dir.getAbsolutePath() );
       
        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();
       
        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );
       
        assertTrue( content.indexOf( "Override: filter-local-override" ) > -1 );
View Full Code Here

   
    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "generate-from-bundle" );
        Verifier verifier = new Verifier( dir.getAbsolutePath() );
       
        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();
       
        File output = new File( dir, "target/maven-shared-archive-resources/DEPENDENCIES" );
        String content = FileUtils.fileRead( output );
       
        assertTrue( content.indexOf( "Built-In:" ) > -1 );
View Full Code Here

    public void test()
        throws IOException, URISyntaxException, VerificationException
    {
        File dir = TestUtils.getTestDir( "run-only-at-execution-root" );

        Verifier verifier;

        verifier = new Verifier( new File( dir, "resource-projects" ).getAbsolutePath() );
        verifier.executeGoal( "deploy" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        verifier = new Verifier( dir.getAbsolutePath() );

        verifier.deleteArtifacts( "org.apache.maven.plugin.rresource.it.mrr41" );

        verifier.executeGoal( "generate-resources" );
        verifier.verifyErrorFreeLog();
        verifier.resetStreams();

        String depResource = "target/maven-shared-archive-resources/DEPENDENCIES";
        File output = new File( dir, depResource );
        assertTrue( output.exists() );
       
View Full Code Here

TOP

Related Classes of org.apache.maven.it.Verifier

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.