0
votes

Hi i'm trying to implement testlink plugin in jenkins.

I followed this tutorial http://tupilabs.com/books/jenkins-testlink-plugin-tutorial/en/book.pdf

I can build the project but the test isn't run. there is a file not found error I don't understand where i have to put my testfile. I supposed the output format must be TestNG, but where i have to put it ?

Thanks for your answer

2
I use the tutorial which says to create a free style project. I looked at the error i get when i build the project : Cannot run program "mvn.bat" (in directory "d:\.jenkins\jobs\Try1\workspace"): CreateProcess error=2, File not found So i think i have a problem with maven but i have no idea what it could be... thx in advance for ur helpAloys Fortier

2 Answers

1
votes

I had exactly the same problem with building project, when I was following through tutorial placed in book Jenkins:The Definitive Guide. I had Jenkis (jenkins-1.502.msi) instaled on Windows7 64 as a service - whatever I tried always received:

[workspace] $ mvn.bat
The system cannot find the file specified
FATAL: command execution failed
java.io.IOException: Cannot run program "mvn.bat" (in directory "C:\Work\jenkins\jobs\gameoflifedefault\workspace"): CreateProcess error=2, The system cannot find the file specified

Unfortunately I didn't managed to resolve this jenkis service problem but found another solution to make it work on Windows: Use Apache Tomcat java server - if you have properly configured Tomcat do:

  1. Download jenkins.war
  2. Place it in webapps folder in your Tomcat directory
  3. Run Tomcat and check via http://localhost:8080/manager if jenkins is there
  4. Go to http://localhost:8080/jenkins

Now mvn.bat is seen and my build run without problems.

Ofcourse I understand that maven is properly configured on your system - so you should had specified in environmental variables:

  • variable: M2
    value: %M2_HOME%\bin
  • variable: M2_HOME
    value: C:\yourPathToMaven\apache-maven-3.0.4
  • variable: PATH
    add to existing value: %M2_HOME%;

To check if maven is visible type in comand promp:

C:\Users\x>mvn --version

You should get something like:

 Apache Maven 3.0.4 (r1232337; 2012-01-17 09:44:56+0100)
    Maven home: C:\Work\Maven\apache-maven-3.0.4
    Java version: 1.7.0, vendor: Oracle Corporation
    Java home: C:\Work\ja\jdk1.7.0_10\jre
    Default locale: en_US, platform encoding: Cp1250
    OS name: "windows 7", version: "6.1", arch: "amd64", family: "windows"

Hope it helps.

0
votes

Update : I found that the error was : Cannot run program mvn.bat in directory d:/jenkins/jobs/JobTest/workspace CreateProcess error=2 File not found.

I made a free style project as said in the tutorial. It seems to be a maven error so i don't understand ...

If somebody can help me i'd be gratefull