Jenkins: Running remote test scripts and reporting results
I'm trying to take Jenkins from a CI machine, and I would like to have it begin to automatically start testing o开发者_运维问答f the applications it builds.
My setup is this:
- 1 central build server
- 8 dedicated test machines.
Currently when build is finished (and label applied), we manually walk around, install the new build, and begin the tests. The tests each take 8-24 hours, so running them in parallel is pretty necessary. Later on, we walk around and see the results.
I'd like to automate:
- Distribution of the build
- Installation of the program
- Beginning of the test scripts
- Collection of the data.
I'm assuming I can use Jenkins for all of this, but I haven't been able to find a good / easy tutorial that tells me how to do this. I'm sure it involves installing the 'slave' service on all the test machines, but the instructions for even that don't seem to be working very well.
Any ideas for a good tutorial? Any pointers from all of you? Thanks!
Since your builds are done on the master, I'm assuming you are going to require this:
http://wiki.jenkins-ci.org/display/JENKINS/Copy+To+Slave+Plugin
I would try something like this:
Create Job # 1 that builds your application/program/library/whatever else.
Create Job #2
- Use this job and the above plugin to copy over the resultant files over to the test slave
- Use this job to install the artifacts that were copied over by job #1 using the "Windows Batch Command" build step.
- Use this job to run your tests
Use the "Build other projects" option under "Post build actions" in Job #1 to trigger Job #2. This can be a multi-configuration project, so you can pick multiple slaves for it.
This way, anytime you start Job #1, and it is successful, #2 will be triggered, and it will copy over files, install them, and start the test.
Two things I've assumed here: your software can be installed via command line, and that it can be installed without human intervention, or at least using some sort of script.
You might also find Jenkins/Hudson creator Kohsuke Kawaguchi's new white paper helpful... 7 Ways to Optimize Jenkins
精彩评论