1
votes

'''

[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  43.645 s
[INFO] Finished at: 2020-04-27T00:17:30+05:45
[INFO] ------------------------------------------------------------------------
Waiting for Jenkins to finish collecting data
[JENKINS] Archiving /Users/suraj/git/CrmTest/FreeCRMTest/pom.xml to 
FreeCRMTest/FreeCRMTest/0.0.1-SNAPSHOT/FreeCRMTest-0.0.1-SNAPSHOT.pom
[JENKINS] Archiving /Users/suraj/git/CrmTest/FreeCRMTest/target/FreeCRMTest-0.0.1- 
SNAPSHOT.jar to FreeCRMTest/FreeCRMTest/0.0.1-SNAPSHOT/FreeCRMTest-0.0.1-SNAPSHOT.jar
/Users/suraj/git/CrmTest/FreeCRMTest/pom.xml is not inside 
/Users/suraj/.jenkins/workspace/FreeCRMMaven/Users/suraj/git/CrmTest/FreeCRMTest/; will 
archive in a separate pass
/Users/suraj/git/CrmTest/FreeCRMTest/target/FreeCRMTest-0.0.1-SNAPSHOT.jar is not inside 
/Users/suraj/.jenkins/workspace/FreeCRMMaven/Users/suraj/git/CrmTest/FreeCRMTest/; will 
archive in a separate pass
ERROR: Failed to parse POMs
java.nio.file.NoSuchFileException: 
/Users/suraj/.jenkins/workspace/FreeCRMMaven/Users/suraj/git/CrmTest/FreeCRMTest/pom.xml
at sun.nio.fs.UnixException.translateToIOException(UnixException.java:86)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102)
at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107)
at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214)
at java.nio.file.Files.newByteChannel(Files.java:361)
at java.nio.file.Files.newByteChannel(Files.java:407)
at java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:384)
at java.nio.file.Files.newInputStream(Files.java:152)
at hudson.FilePath.read(FilePath.java:1942)
at 

jenkins.plugins.maveninfo.extractor.properties.PomPropertiesFinder.findProperties(PomPropertiesF. inder.java:50) at jenkins.plugins.maveninfo.extractor.MavenInfoExtractor.extract(MavenInfoExtractor.java:58) at jenkins.plugins.maveninfo.extractor.MavenInfoEnvironment.tearDown(MavenInfoEnvironment.java:42) at

hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.doRun(MavenModuleSetBuild.java:908) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:504) at hudson.model.Run.execute(Run.java:1856) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:428) channel stopped

TestNG Reports Processing: START Looking for TestNG results report in workspace using pattern: **/testng-results.xml Did not find any matching files. Finished: FAILURE

'''

Jenkins Maven Project

Global Tool Configuration java

Global Tool configuration maven

Java Installed version

pom.xml

'''

        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.8.1</version>
            <configuration>
                <source>1.8</source>
                <target>1.8</target>
            </configuration>
        </plugin>


        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <version>3.0.0-M4</version>
            <configuration>
                <suiteXmlFiles>                 <suiteXmlFile>/Users/suraj/git/CrmTest/FreeCRMTest/src/main/resources/testng.xml</suiteXmlFile>
                </suiteXmlFiles>
            </configuration>
        </plugin>
    </plugins>
</build>

'''

1

1 Answers

0
votes

Under Build in Root POM field mention only "pom.xml" and below "Goals and options" field click on advanced and then click on "Use custom work space" and here mention the path of your project directory("/Users/suraj/git/CrmTest/FreeCRMTest/"). Add project directory path