I have Selenium+Eclipse+Java Project+Eclipse TestNG plugin. For example, my code is:
public class TestClass {
@Test
public void test1() throws Exception {
...
}
//@Test
public void test2() throws Exception {
...
}
When i run TestClass as TestNG, both tests are executed. I can't understand why test2 is executed also. Because there is a comment "//" before @Test annotations.
Any ideas? thanks in advance
首先,您应该清理类文件,然后再次编译项目
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.