我有一个叫做Yslow test的构建。构建失败是由于一些yslow测试失败(据我所知)。
有没有办法将其设置为Jenkins不会将构建标记为“失败”,而不管yslow测试如何?
Shell:
/usr/local/bin/phantomjs yslow.js -i grade -t 50 -f junit http://www.website.com > yslow.xml
控制台输出:
Build step 'Execute shell' marked build as failure
Recording test results
Finished: FAILURE
发布于 2014-08-06 21:03:52
你可以使用groovyPostbuild插件来实现这一点。下面这样的代码应该是有效的:
if(manager.logContains(".*Build step 'Execute shell' marked build as failure.*")) {
manager.build.@result = hudson.model.Result.SUCCESS
}
https://stackoverflow.com/questions/25064874
复制相似问题