Category分类测试报错:Category annotations on Parameterized classes are not supported on individual methods.

未解决

Category分类测试报错:Category annotations on Parameterized classes are not supported on individual methods.


CategoryTest.java

@RunWith(Categories.class)
@Categories.IncludeCategory({CatTest.class})
@Suite.SuiteClasses({NextDateTest.class, CalculatorTest.class})
public class CategoryTest {

}

NextDateTest.java内

@Category({CatTest.class})
@Test
public void testGetNextDate_cat(){
    assertEquals(1,1);
}
原文地址:https://www.cnblogs.com/musecho/p/12993783.html