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 196465 - NoSuchMethodError: org.netbeans.modules.junit.Bundle.junitlib_confirm_text()Ljava/lang/String;
Summary: NoSuchMethodError: org.netbeans.modules.junit.Bundle.junitlib_confirm_text()L...
Status: CLOSED INVALID
Alias: None
Product: java
Classification: Unclassified
Component: JUnit (show other bugs)
Version: 7.0
Hardware: All All
: P2 normal (vote)
Assignee: Yulia Novozhilova
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-09 07:15 UTC by Martin Fousek
Modified: 2011-03-11 09:00 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 177393


Attachments
stacktrace (2.91 KB, text/plain)
2011-03-09 07:15 UTC, Martin Fousek
Details
patch for fixing this (823 bytes, text/plain)
2011-03-09 08:04 UTC, Martin Fousek
Details
Patch (824 bytes, patch)
2011-03-09 12:32 UTC, Yulia Novozhilova
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Fousek 2011-03-09 07:15:14 UTC
Build: NetBeans IDE Dev (Build 110308-a13d1e436b6d)
VM: Java HotSpot(TM) 64-Bit Server VM, 19.0-b09, Java(TM) SE Runtime Environment, 1.6.0_23-b05
OS: Linux

User Comments:
marfous: 1, created bean with method
2, wanted to generate JUnit tests
3, invoke on the file Tools->Generate Junit
-> exception appears




Stacktrace: 
java.lang.NoSuchMethodError: org.netbeans.modules.junit.Bundle.junitlib_confirm_text()Ljava/lang/String;
   at org.netbeans.modules.junit.DefaultPlugin.storeProjectSettingsJUnitVer(DefaultPlugin.java:1431)
   at org.netbeans.modules.junit.DefaultPlugin.createTestActionCalled(DefaultPlugin.java:1145)
   at org.netbeans.modules.junit.plugin.JUnitPlugin$1.createTestActionCalled(JUnitPlugin.java:77)
   at org.netbeans.modules.junit.CreateTestAction.performAction(CreateTestAction.java:296)
   at org.openide.util.actions.NodeAction$DelegateAction$1.run(NodeAction.java:586)
   at org.openide.util.actions.ActionInvoker$1.run(ActionInvoker.java:95)
Comment 1 Martin Fousek 2011-03-09 07:15:19 UTC
Created attachment 106841 [details]
stacktrace
Comment 2 Martin Fousek 2011-03-09 07:42:47 UTC
Increasing priority - it's impossible to generate JUnits now.
Definitely showstopper.
Comment 3 Martin Fousek 2011-03-09 08:04:29 UTC
Created attachment 106842 [details]
patch for fixing this
Comment 4 Martin Fousek 2011-03-09 08:08:48 UTC
It seems that it could fix really easy patch because there is just unfinished HTML tag in the bundle.

I'm proposing to mark the issue as 70_HR_FIX_CANDIDATE, do you agree?
Comment 5 Petr Jiricka 2011-03-09 09:54:06 UTC
Yes, all P2s in the "before cut-off" column on the bug dashboard should automatically be 70_HR_FIX_CANDIDATE.
Comment 6 Yulia Novozhilova 2011-03-09 11:23:06 UTC
Attaching a patch. Will be integrated as soon as core-main is open.
Comment 7 Yulia Novozhilova 2011-03-09 12:32:11 UTC
Created attachment 106853 [details]
Patch
Comment 8 Jesse Glick 2011-03-09 16:36:02 UTC
Patch doesn't make any sense to me. Perhaps the reporter was just using an incorrectly built module JAR?
Comment 9 Martin Fousek 2011-03-10 07:05:56 UTC
Sorry, you are right, in the newest build works well also with the unfinished tag.

Strange to me is how it knew new NbBundle.Messages API then, but as a probable reason sounds to me that I forgot after getting new HG changes rebuild so it was rebuild once I made changes. Sorry for invalid issue.
Comment 10 Marian Mirilovic 2011-03-10 09:37:06 UTC
v/c
Comment 11 Tomas Danek 2011-03-10 13:39:10 UTC
just happend to me, see my last submit. 
I am using IDE freshly built from core-main AFAIK i did:

hg pull -u
ant

which should not generate any invalid JARs?! Or did i miss something?!
Comment 12 Tomas Danek 2011-03-10 13:46:53 UTC
Copy-paste of my steps to reproduce from report:

- custom core-main build
- IDE did not contain JUnit, opened previously created project which contained reference to JUnit
- ignored "Resolve reference problem", closed project
- opened another one, without test
- tried ti invoke on some class Tools|Create JUnit test
--> entry point did not work, got NSME

please note, that it is problem in this entry point, another entry point works. While creating of JUnit tests via Tools| Create JUnit failed with NSME, i was able to install JUnit via Resolve broken references later without any problems (after opening project containing references to tests).
Comment 13 Jesse Glick 2011-03-10 15:09:31 UTC
(In reply to comment #11)
> I am using IDE freshly built from core-main AFAIK i did:
> 
> hg pull -u
> ant

In general you should use the sequence:

ant clean
hg pull -u (or hg fetch)
ant

Otherwise it is not "freshly built". That said, if you can find a specific test case which reproducibly causes the Bundle.class method to be missing after an incremental build, file a P3 for me in platform/Other blocking bug #192750.
Comment 14 Tomas Danek 2011-03-11 09:00:51 UTC
you are right, unable to reproduce now. Closing.