【发布时间】:2012-08-09 08:32:01
【问题描述】:
我想了解是否可以在 gradle 测试任务中指定@category。所以,I can run separately integration junits and the normal junit tests。
我知道目前有no explicit support for @category in gradle,我正在寻找解决此限制的方法。
直接的方法是为不同的测试类别定义测试套装,例如How to run all tests belonging to a certain Category in JUnit 4。我希望在我的 gradle 脚本中指定 @category。
【问题讨论】:
-
ps。将集成测试放在单独的目录中要容易得多:src/integration-test/。这种方法还使得测试的分离更容易被团队成员维护和遵循。