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 230795 - When I try to run a focus test it keeps complaining I need to set Compile on Save.
Summary: When I try to run a focus test it keeps complaining I need to set Compile on ...
Status: RESOLVED FIXED
Alias: None
Product: utilities
Classification: Unclassified
Component: Test Runner (show other bugs)
Version: 7.2
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: Theofanis Oikonomou
URL:
Keywords: REGRESSION
Depends on:
Blocks:
 
Reported: 2013-06-05 14:13 UTC by aquaglia
Modified: 2013-06-13 06:48 UTC (History)
0 users

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 aquaglia 2013-06-05 14:13:28 UTC
Product Version: NetBeans IDE Dev (Build nbms-and-javadoc-11075-on-20130604)

Updates: Updates available

Java: 1.7.0_21; Java HotSpot(TM) 64-Bit Server VM 23.21-b01

Runtime: Java(TM) SE Runtime Environment 1.7.0_21-b11

System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)

User directory: C:\Users\quaglan\AppData\Roaming\NetBeans\dev

Cache directory: C:\Users\quaglan\AppData\Local\NetBeans\Cache\dev


I have a Java Maven project where Compile on Save is checked.
When I try to run a focus test it keeps complaining I need to set Compile on Save.

No problem if I use:

Product Version: NetBeans IDE 7.3 (Build 201302132200)

I had to switch back to this version.
Comment 1 Theofanis Oikonomou 2013-06-06 10:22:01 UTC
You need to have Surefire 2.8+ with JUnit 4.8+ or TestNG in order to run a single test method. Can you describe your set-up and reopen. Thank you
Comment 2 aquaglia 2013-06-06 12:29:06 UTC
I think I did not make myself clear.
I do not have neither Surefire 2.8+ with JUnit 4.8+ nor TestNG but Copmile on Save is set to true.
The very same project works fine in 7.3.

If I open it with the Build nbms-and-javadoc-11075-on-20130604 it does not work anymore.
Comment 3 Theofanis Oikonomou 2013-06-06 12:56:53 UTC
I cannot reproduce unless you give me some more info about your problem, eg project type, testing framework etc. Also steps to reproduce. Thank you
Comment 4 aquaglia 2013-06-10 07:11:16 UTC
Hi,
I have sent you (theofanis@netbeans.org) one of the projects where I have the problem.
Comment 5 Theofanis Oikonomou 2013-06-10 09:33:43 UTC
Please see http://wiki.netbeans.org/FaqCompileOnSave#Using_Compile_on_Save_in_Maven_Projects for more information on the changed behavior.

I updated the message as it is causing confusion.
So,if you change your junit test dependency to eg 4.10 you will be able to test focused method.

Fixed:http://hg.netbeans.org/core-main/rev/24293f8f8426
Comment 6 Quality Engineering 2013-06-12 02:02:09 UTC
Integrated into 'main-golden', will be available in build *201306112301* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/24293f8f8426
User: Theofanis Oikonomou <theofanis@netbeans.org>
Log: #230795 - When I try to run a focus test it keeps complaining I need to set Compile on Save.
Comment 7 aquaglia 2013-06-13 06:48:02 UTC
I have upgraded to JUnit 4.10 and everything works.
Many thanks.