问题描述
我正在使用Jenkins进行构建,并且编写了一些在构建编译后需要运行的测试脚本.我想节省一些时间,因此必须并行运行测试脚本.我该怎么办?
I'm using Jenkins for my builds, and I wrote some test scripts that I need to run after the compilation of the build.I want to save some time, so I have to run the test scripts parallel. How can I do that?
好的,我知道我为每个测试需要一个单独的工作(对于4个测试,我需要4个工作,对吗?)因此,我做到了,并且通过上级工作,我运行了这个工作. (使用构建其他项目"插件).但是我没有设法汇总结果(使用汇总的下游测试结果).父作业在下游作业完成之前退出.我该怎么办?
ok, I understand know that I need a separate Job for each test (for 4 tests I need 4 jobs, right?)So, I did that, and via the parent job I ran this jobs. (using "build other projects" plugin).But I didn't managed to aggregate the results (using aggregate downstream test results). The parent job exits before the downstream jobs were finished.What shall I do?
谢谢.
推荐答案
您可以使用多任务插件.这将允许您并行运行多个作业,而父作业将等待子作业完成.父作业状态可以由子作业状态确定.
You can use multi-job plugin. This would allow you to run multiple jobs in parallel and the parent job would wait for the sub jobs to be completed. The parent jobs status can be determined by the sub jobs status.
https://wiki.jenkins-ci.org/display/JENKINS/多作业+插件
这篇关于在詹金斯(Jenkins)中运行并行作业的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!