Display selenese-runner results in Jenkins

217 views Asked by At

As I am implementing an automated way to GUI test our webapplication with selenium I ran into some issues.

I am using selenese-runner to execute our Selenium test suites, created with Selenium IDE as a post build action in Jenkins.

This works perfeclty fine, as the build fails when something is wrong, and the build succeeds if all tests are passed. And the results are stored on a per build basis as HTML files, generated be selenese-runner.

My problem is however, that I seem to be unable to find a way, how to display these results in the respective jenkins build.

Does anyone have an idea how to solve this issue. Or maybe I am on the wrong path at all?

Your help is highly appreciated!

1

There are 1 answers

0
andrew lorien On

I believe the JUnit plugin should do what you want, but it doesn't work for me. My config uses this shell script to run the tests (you can see the names of all my test suites):

/usr/bin/Xvfb &
export DISPLAY=localhost:0.0
cd ${WORKSPACE}
java -jar  ./test/selenium/bin/selenese-runner.jar --baseurl http://${testenvironment}  --screenshot-on-fail  ./seleniumResults/ --html-result ./seleniumResults/ ./test/selenium/Search_TestSuite.html ./test/selenium/Admin_RegisteredUser_Suite.html ./test/selenium/Admin_InternalUser_Suite.html  ./test/selenium/PortfolioAgency_Suite.html  ./test/selenium/FOAdmin_Suite.html  ./test/selenium/PublicWebsite_Suite.html ./test/selenium/SystemAdmin_Content_Suite.html ./test/selenium/SystemAdmin_MetaData_Suite.html
killall Xvfb

And I can see the result of the most recent test (you can see the name of my jenkins task folder)

http://<JENKINS.MY.COMPANY>/job/seleniumRegressionTest/ws/seleniumResults/index.html

Earlier tests are all saved on the Jenkins server, so I can view them if I need to.