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.

Bug 185214 - Upragde JUNIT 4 to the lasted version (4.8.2 currently)
Summary: Upragde JUNIT 4 to the lasted version (4.8.2 currently)
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: JUnit (show other bugs)
Version: 6.x
Hardware: All Other
: P3 normal (vote)
Assignee: Andrey Yamkovoy
URL: http://wiki.netbeans.org/UnitTestingW...
Keywords:
: 173540 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-04-28 23:50 UTC by hantsy
Modified: 2010-06-18 03:20 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description hantsy 2010-04-28 23:50:25 UTC
The latest JUnit 4.8 introduce a sexual feature- GROUP, you can categorized UnitTest to different group.
Please upgrade the JUNIT 4 shipped by NetBeans IDE to the lastest version.
If possible, support the Group feature in the JUnit Runner view(TopComponent), user can a batch of UnitTest different group.
Comment 1 Alexei Mokeev 2010-05-05 10:00:09 UTC
*** Bug 173540 has been marked as a duplicate of this bug. ***
Comment 2 Victor Vasilyev 2010-05-12 22:57:46 UTC
It is addressed to the next release.
See also:
http://wiki.netbeans.org/UnitTestingWantedItems
http://wiki.netbeans.org/JUnit_4.8
Comment 3 hantsy 2010-05-13 05:33:33 UTC
I am a XP practicer. I would like use JUnit/TestNG other than Debugger provided by IDE.

The TestNG is still not available in NetBeans IDE(I used the nightly build version, found the editor context action is different from Junit, and it is prolematic at runtime ). A more fexiable TestRunner SPI/API needed for all unit framework, not only for JUnit/TestNG, but junit variants in t others language.

Another problem is performance when run a JUnit Test. I found the JUnit runner is not effective  in NetBeans. Compared to other alternatives, such Eclipse JUnit support, and the JUnit swing UI, it is slowly.

The better is I beg NetBeans provide a united Test/Run/Profile/Coverage API/SPI (I have filed this issue),provide a united UI to end user, like Eclipse/IDEA.

https://netbeans.org/bugzilla/show_bug.cgi?id=168208
Comment 4 Alexei Mokeev 2010-05-13 06:37:20 UTC
To the comment #3:

>The TestNG is still not available in NetBeans IDE(I used the nightly build
>version, found the editor context action is different from Junit, and it is
>prolematic at runtime ).
TestNG is an external plugin and provided by community. Certainly we are welcome bugs/enchantments that are required to make this plug-in working, but we do not maintain the plug-in itself.


>A more fexiable TestRunner SPI/API needed for all unit
>framework, not only for JUnit/TestNG, but junit variants in t others language.
Yep. Currently the infrastructure for processing test results is shared for other junit variants (e.g PHP and others). But can be extended, e.g code generation, simplicity, etc

>Another problem is performance when run a JUnit Test. I found the JUnit runner
>is not effective  in NetBeans. Compared to other alternatives, such Eclipse
>JUnit support, and the JUnit swing UI, it is slowly.
This very important point. Could you please specify what specifically _is slow_ ?
Comment 5 hantsy 2010-05-14 14:25:28 UTC
If I perform a "Run File" in a JUnit Test file, it will execute a series of ant targets before run this test file. If a project has handreds of java files, this process may be took much time.
If I enable COS(compile on save), these steps are nessessary? Further more, I run a single test, the compile process should focus on the dependency tree of the Test class, not the whole project.
Comment 6 tomwheeler 2010-06-02 22:19:53 UTC
I agree with this issue.  The version of JUnit (4.5) currently shipping with NetBeans 6.9 is nearly two years old.  

JUnit 4.8 introduces a number of new and useful features that would be useful to most developers.  AFAIK, any tests developed even as far back as JUnit 3.x should run without modification in JUnit 4.8 so this should be a simple upgrade to make.
Comment 7 Andrey Yamkovoy 2010-06-16 09:48:33 UTC
Fixed in the main (changeset: 474e5cc4332f).
Comment 8 Jesse Glick 2010-06-16 15:36:07 UTC
Some matching changes in core-main #dc04335b90ac, most importantly to make 'ant localtest' (i.e. nbbuild unit tests) work again.
Comment 9 Quality Engineering 2010-06-17 03:19:58 UTC
Integrated into 'main-golden', will be available in build *201006170001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/474e5cc4332f
User: Andrey Yamkovoy <kaktus@netbeans.org>
Log: Fix for #185214 -  Upragde JUNIT 4 to the lasted version (4.8.2 currently)
Comment 10 Quality Engineering 2010-06-18 03:20:43 UTC
Integrated into 'main-golden', will be available in build *201006180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/dc04335b90ac
User: Jesse Glick <jglick@netbeans.org>
Log: #185214 cont'd: JUnit 4.8.2 upgrade.