简体   繁体   English

显示selenese-runner导致Jenkins

[英]Display selenese-runner results in Jenkins

As I am implementing an automated way to GUI test our webapplication with selenium I ran into some issues. 当我使用selenium实现GUI测试web应用程序的自动化方法时,遇到了一些问题。

I am using selenese-runner to execute our Selenium test suites, created with Selenium IDE as a post build action in Jenkins. 我正在使用selenese-runner来执行我们的Selenium测试套件,使用Selenium IDE作为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. 结果存储在每个构建的基础上作为HTML文件,生成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. 然而,我的问题是,我似乎无法找到方法,如何在相应的jenkins构建中显示这些结果。

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! 非常感谢您的帮助!

I believe the JUnit plugin should do what you want, but it doesn't work for me. 我相信JUnit插件应该做你想要的,但它对我不起作用。 My config uses this shell script to run the tests (you can see the names of all my test suites): 我的配置使用这个shell脚本来运行测试(你可以看到我所有测试套件的名称):

/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) 我可以看到最近测试的结果(你可以看到我的jenkins任务文件夹的名称)

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. 早期的测试都保存在Jenkins服务器上,因此如果需要,我可以查看它们。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM