本文介绍了如何将非并行junit参数化测试转换为并行运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我写了一个参数化的junit测试。
I write a parameterized junit test.
有没有内置的方法让它并行运行? @annoation
例如?
Is there any built-in way to make it run in parallel? any @annoation
for example?
如果没有,我唯一的方法是手动编写 -
If not, and my only way is to write this manually -
如何管理junit中的线程池,java?
how would you manage a thread pool in junit, java?
推荐答案
库提供了转轮。替换
@RunWith(Parameterized.class)
public class YourTest {
与
@RunWith(ParallelParameterized.class)
public class YourTest {
这篇关于如何将非并行junit参数化测试转换为并行运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!