Sign up ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

I have written quite a few Ruby programs for my clients test automation project.But the problem is my client wants to check the output to his PC without instilling ruby.He is asking me to make one web application where he can select functionality from drop down and run the automation by clicking run button.And after completion the test it will auto generate a test result.

I got an advice from an expert.He is asking me to use Jenkins and CI Reporter.But the problem is i am novice and do not know to use Jenkins and how to setup my automation script to Jenkins.

Can any body tell me-"How to setup Jenkins a server and where to integrate my ruby script which can hit virtually from anywhere and trigger selenium script to execute all the functional tests and all your client has to do is hit a "Play" button to execute them."

share|improve this question

2 Answers 2

Unfortunately I cannot help you with installing Jenkins (though I don't think it's really difficult) because in my case I already had it installed by DevOps people.

But creating a new job that runs your automated tests is not a big deal. Before doing this please check following things:

  1. If you want Jenkins to show fancy graphs with tests results (without this there is probably not much sense in setting up this job) you need to be sure that the tool/framework you use is capable of saving the test results to the XML files with special structure recognised by Jenkins/Hudson. Some of the tools have this support out of the box, for some others you will have to install additional libraries.

  2. To login on the remote server and execute scripts there you need an SSH access to that server and you need to add those credentials to the settings of Jenkins. For this, open '/configure' URL in Jenkins and find 'SSH remote hosts' session. Click 'Add' button to add new credentials and don't forget to save the settings afterwards.

  3. You MIGHT have issues with one machine not capable to login to another via SSH because of missing certificates, so you need to double-check this with your system administrators/DevOps.

After this, do the following:

  1. Hit the 'New item' button on the left side of Jenkins main page

  2. Choose 'New freestyle project'

  3. On the top, enter project name and description

  4. Scroll down and click 'Add build step' button. Select 'Execute shell script on remote host using ssh'. In 'SSH site' drop-down, select your SSH credentials and enter the command in 'Command' field. In my case, I had a bash script which spins up a vagrant machine that checks out the latest test version and runs them against another server. The commands in my case are looking like this:

cd /var/acceptance-tests/


sshpass -p "password" scp -r /var/acceptance-tests/output$WORKSPACE

With first command I navigate to the folder with bash script, then I run it and with the last command I copy the results in XML to the server where Jenkins is located (unfortunately I don't know better way to do it other than using sshpass util and in this case I need to write a password in plain text).

  1. Click 'Add post-build action' and choose 'Publish JUnit test result report'. For the example, above 'Test report XMLs' field value would be '\output*.xml'. Check 'Retain long standard output/error' checkbox as well.

That's basically all (in this example I'm not covering additional settings you may change in the job).

share|improve this answer

You probably want to follow the Jenkins tutorial. Here is a good one.

share|improve this answer
Could you please add a summary of the tutorial you've linked to your answer? Links can die, but if the information is present in the answer, it remains useful. –  Kate Paulk Mar 10 '14 at 11:15

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.