This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Product Version: NetBeans IDE Dev (Build 201202010600) Java: 1.7.0_02; Java HotSpot(TM) 64-Bit Server VM 22.0-b10 System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb) User directory: C:\Users\Gili\.netbeans\dev Cache directory: C:\Users\Gili\.netbeans\dev\var\cache 1) Open the project found at http://bbs.darktech.org/TestNG.zip 2) Place a breakpoint at org.pill.JavaCompilerTest 3) Hit CTRL+SHIFT+F6 4) Notice debugger does not hit breakpoint 5) Netbeans outputs: Testsuite: org.pill.JavaCompilerTest Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0.1 sec Testcase: initializationError(org.pill.JavaCompilerTest): Caused an ERROR No runnable methods java.lang.Exception: No runnable methods at java.lang.reflect.Constructor.newInstance(Constructor.java:525) 6) This leads me to believe that the testcase is run (not in debug mode) and then JUnit is fired against the same class and complains it can't find any tests.
reproduced, you're right. In this case global debugging actions do not work. OTOH there are provided 2 possible workarounds for now: -use custom TestNG -> Debug (= Debug Focused Test) or -> TestNG -> Debug Test Class (same as CTRL+SHIFT+F6) actions available in java editor's context menu -add <import file="nbproject/testng-impl.xml"/> to project's build script before <import file="nbproject/build-impl.xml"/> - this case global debugging actions and shortcuts (such as CTRL+SHIFT+F6) will work (http://hg.netbeans.org/main/contrib/rev/b4619fb1e7af) as this is something which simply has to work => P2 (given there are workarounds available) basic problem here is that projects' test debugging targets are not extensible and there's no simple way to override them with current NetBeans APIs (-debug-start-debuggee-test is the culprit here) tentative solution for pre-7.2 (7 and 7.1.x) will most likely be to ask user to allow direct modification of build.xml by inserting <import file="nbproject/testng-impl.xml"/> before other imports there solution for 7.2 will depend on testng author(s) (wrt accepting patch provided there) and eventually on broader agreement between other NetBeans teams (mainly java se, java ee, mobility?, core?, others?) - more about this will be available on the wiki by the end of this week
already part of the IDE...
*** This bug has been marked as a duplicate of bug 208841 ***