TestNG-J 0.5.0 for IntelliJ IDEA released
testng testing intellij java plugin
Along with the recent project level TestNG settings I mentioned the other day, Hani commited a few bug fixes to the plugin so I've gone and pushed out a new build to the IntelliJ Plugin Manager - updates include:
- Fixed 100% CPU usage if a class accidentally extends itself
- Fixed occassional ConcurrentModificationException error
- Correctly highlight invalid configuration icon if invalid class/package specified
- Use module JDK if module classpath is specified instead of project JDK
- Added experimental support for automatically detecting and including group dependency when running a single class or method
- Group browser now only shows groups from the current module, rather than the whole project, which should speed it up significantly
- Added project level configuration for default parameters and test output directory
- Added test output directory setting to run configuration.

Grab it from the plugins website or direct from the IntelliJ Plugin Manager.
Comments (8)
Hi Mark,
Oh, that's rather vital information, it's itellij7.0.3. Somehow when over a test class, right-clicking the mouse doesn't show up the run/debug class options and I don't know how to get them back. I went back to intellij 6 because 7 is a bit heavy on my computer so that pretty much solved the issue for me, don't know if other people have the same problem. Thanks for your quick reply Mark. Cheers, MarcHey Marc - since IDEA 7.0 the TestNG plugin ships with the IDE. You don't mention what version of IDEA you're using, or what version of the plugin.
Hi all,
Could anyone help me out with the testng plugin? I ty to install it but intellij doesn't install the plugin, it keeps showing up under the not installed area in the plugin section. Does anybody have any idea? Manually createing a testrunner dir in the plugin dir doesn't work either. Thanks in advance, MarcIgor - that exception triggers inside IntelliJ's OpenAPI library so I'm unable to fix anything directly. Have you tried using the recently released 6.0.2 release?
If you're able to reproduce the exception in a standalone project it would be good to get a copy (email a zip to talios at gmail.com). It's probably something in the way your using annotations in your project. Thanks, MarkWith new version of plugin I received following IDEA exception, when try to run TestNG tests:
java.lang.NullPointerException at com.intellij.codeInsight.AnnotationUtil.findAnnotation(AnnotationUtil.java:73) at com.theoryinpractice.testng.util.TestNGUtil.filterAnnotations(TestNGUtil.java:148) at com.theoryinpractice.testng.TestNGRunnableState.calculateDependencies(TestNGRunnableState.java:415) at com.theoryinpractice.testng.TestNGRunnableState.createJavaParameters(TestNGRunnableState.java:245) at com.intellij.execution.configurations.JavaCommandLineState.getJavaParameters(JavaCommandLineState.java:30)I use IntelliJ IDEA 6.0.1, build #5784. Is there any way to fix this issue? Maybe there are some problem in my IDEA configuration. PS: Thanks for this plugin!
Hi Wim, it's not possible via the project/package manager (great idea thou...) but you can create a new run profile and select package from the 'Run->Edit Configurations' menu easily enough.
Is it possible to add support for running a package? Using JUnit in IntelliJ, I sometimes run all tests in a certain package by right-clicking on the package in the project view and choosing "run tests". This does not seem to work with TestNG currently.
The plugin should just work under 7.0.3 - does the plugin show as being installed/enabled in the plugin manager? If you want click the "chat with mark" link in the upper right corner of the blog and if I'm here we'll see if we can work out whats wrong...