Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-43714

withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      The "withMaven()' wrapper sees the "generated artifact" of "mvn test" as a file that can be archived and fingerprinted when it is just the folder "${project.build.output}.

      XML fragment of the MAven Event Spy report that is causing confusion

        <ExecutionEvent type="ProjectSucceeded" class="org.apache.maven.lifecycle.internal.DefaultExecutionEvent" _time="2017-04-19 23:39:04.293">
          <project baseDir="/path/to/workspace" file="/path/to/workspace/pom.xml" groupId="jenkins.mvn.test" name="mono-module-maven-app" artifactId="mono-module-maven-app" version="0.1-SNAPSHOT">
            <build sourceDirectory="/path/to/workspace/src/main/java" directory="/path/to/workspace/target"/>
          </project>
          <no-execution-found/>
          <artifact extension="jar" groupId="jenkins.mvn.test" artifactId="mono-module-maven-app" id="jenkins.mvn.test:mono-module-maven-app:jar:0.1-SNAPSHOT" type="jar" version="0.1-SNAPSHOT">
            <file>/path/to/workspace/target/classes</file>
          </artifact>
          <attachedArtifacts/>
        </ExecutionEvent>
      

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Cyrille Le Clerc
            Path:
            jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java
            jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java
            http://jenkins-ci.org/commit/pipeline-maven-plugin/5cafe419618d7db7b039425acc86451be603535e
            Log:
            JENKINS-43714 fixe withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it
            Add integration tests with maven-plugin-project and Jenkins-hpi-project

            Compare: https://github.com/jenkinsci/pipeline-maven-plugin/compare/896afe039b8e^...5cafe419618d

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Cyrille Le Clerc Path: jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java http://jenkins-ci.org/commit/pipeline-maven-plugin/5cafe419618d7db7b039425acc86451be603535e Log: JENKINS-43714 fixe withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it Add integration tests with maven-plugin-project and Jenkins-hpi-project Compare: https://github.com/jenkinsci/pipeline-maven-plugin/compare/896afe039b8e ^...5cafe419618d
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Cyrille Le Clerc
            Path:
            jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java
            jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java
            http://jenkins-ci.org/commit/pipeline-maven-plugin/e379617f7247103a1efe3f2e127bd350f8881f08
            Log:
            JENKINS-43714 fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it
            Add integration tests with maven-plugin-project and Jenkins-hpi-project

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Cyrille Le Clerc Path: jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java http://jenkins-ci.org/commit/pipeline-maven-plugin/e379617f7247103a1efe3f2e127bd350f8881f08 Log: JENKINS-43714 fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it Add integration tests with maven-plugin-project and Jenkins-hpi-project
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Cyrille Le Clerc
            Path:
            jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java
            jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java
            http://jenkins-ci.org/commit/pipeline-maven-plugin/1455ad2eebf0d7d597a7410c3568d7f296a87b1c
            Log:
            JENKINS-43714 fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it
            Add integration tests with maven-plugin-project and Jenkins-hpi-project

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Cyrille Le Clerc Path: jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java http://jenkins-ci.org/commit/pipeline-maven-plugin/1455ad2eebf0d7d597a7410c3568d7f296a87b1c Log: JENKINS-43714 fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it Add integration tests with maven-plugin-project and Jenkins-hpi-project
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Cyrille Le Clerc
            Path:
            jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/MavenSpyLogProcessor.java
            jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java
            jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java
            jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java
            http://jenkins-ci.org/commit/pipeline-maven-plugin/70cbc0a9b3366bd4896a3e813b896d078d0931a5
            Log:
            Merge pull request #41 from jenkinsci/JENKINS-43714

            [Jenkins 43714] fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it

            Compare: https://github.com/jenkinsci/pipeline-maven-plugin/compare/1b779fe898fc...70cbc0a9b336

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Cyrille Le Clerc Path: jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/MavenSpyLogProcessor.java jenkins-plugin/src/main/java/org/jenkinsci/plugins/pipeline/maven/reporters/GeneratedArtifactsReporter.java jenkins-plugin/src/test/java/org/jenkinsci/plugins/pipeline/maven/WithMavenStepOnMasterTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/main/java/com/example/MonoModuleMavenApp.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_hpi_project/src/test/java/com/example/MonoModuleMavenAppTest.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_jar_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/.gitignore jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/pom.xml jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/main/java/jenkins/mvn/test/App.java jenkins-plugin/src/test/resources/org/jenkinsci/plugins/pipeline/maven/test/test_maven_projects/maven_plugin_project/src/test/java/jenkins/mvn/test/AppTest.java http://jenkins-ci.org/commit/pipeline-maven-plugin/70cbc0a9b3366bd4896a3e813b896d078d0931a5 Log: Merge pull request #41 from jenkinsci/ JENKINS-43714 [Jenkins 43714] fix withMaven thinks that "mvn test" generates a jar file causing a FileNotFoundException trying to archive it Compare: https://github.com/jenkinsci/pipeline-maven-plugin/compare/1b779fe898fc...70cbc0a9b336
            Hide
            cleclerc Cyrille Le Clerc added a comment -

            Fixed in 2.3.1

            Show
            cleclerc Cyrille Le Clerc added a comment - Fixed in 2.3.1

              People

              • Assignee:
                cleclerc Cyrille Le Clerc
                Reporter:
                cleclerc Cyrille Le Clerc
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: