问题
I have created the simple test class and getting error while executing it "An internal error occurred during: "Launching test". java.lang.NullPointerException".
I am fed up with this problem. I searched a lot on google and applied all the possible solutions but still getting same problem. I know, it is configuration problem but not able to figure out where?
Followed Steps to create the project:
- Open Eclipse
- Install TestNG Plugin
- Create Java Project
- Add TestNG Library
- Create TestNG Class
- Execute that class (as above)
Applied solution :
- Reinstalled the Eclipse.
- Reinstalled the TestNG Plugin
- Uninstalled the MVC TestNG plugin
Source Code:
package usermigration;
import org.testng.annotations.Test;
public class test {
@Test
public void a()
{
System.out.println("a");
}
}
回答1:
Finally I have identified the root cause. I have removed the M2E jars from eclipse and it resolved the problem.
回答2:
looks like it's a regression introduced by PR #351, it should now be fixed in the beta channel: http://beust.com/eclipse-beta
, will deploy a hotfix soon.
-- Edit
now the hotfix 6.12.0.201709050550 is released: https://dl.bintray.com/testng-team/testng-eclipse-release/6.12.0/
来源:https://stackoverflow.com/questions/46041736/an-internal-error-occurred-during-launching-testng-in-eclipse