Suppose I have the following test:
public class TestCase {
@Test
public void test1() {
}
@Test(dependsOnMethods = "test1")
public void test2() {
}
}
If I run test2 in IDEA then I get the following error: org.testng.TestNGException: TestCase.test2() is depending on nonexistent method TestCase.test1
I noticed that IDEA automatically add dependencies for groups so I think it should do the same for method dependencies.