简体   繁体   中英

Define threshold of failures in parameterized test

We have a parameterized test which generates one test for each file in a specified folder and checks whether we can process it or not.

We expect this parameterized test to fail for a lot of files and that's why we have excluded it from our build process (we're using Maven and Jenkins for CI).

The problem is that because this test is not part of our build, sometimes we accidentally cause more failures than what we expect with code changes.

Does anyone know a way to specify, either in the test itself or in the POM, a threshold and say that if we have more failures than the threshold, this parameterized test should cause the build to fail?

Thank you for all your help.

Alex

将其从参数化测试更改为运行列表中所有文件的单个测试,如果太多的测试失败将失败,该怎么办?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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