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 237558 - Failing tests on JDK8
Summary: Failing tests on JDK8
Status: VERIFIED FIXED
Alias: None
Product: projects
Classification: Unclassified
Component: Generic Projects UI (show other bugs)
Version: 8.0
Hardware: All All
: P1 normal (vote)
Assignee: Milos Kleint
URL:
Keywords: JDK_8, JDK_SPECIFIC, TEST
Depends on:
Blocks:
 
Reported: 2013-10-23 13:59 UTC by Jiri Skrivanek
Modified: 2013-11-25 09:48 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
first awt window closing event creation stacktrace (32.52 KB, image/png)
2013-11-05 11:49 UTC, Milos Kleint
Details
second awt window closing event creation stacktrace that only happens on jdk 1.7 (32.72 KB, image/png)
2013-11-05 11:50 UTC, Milos Kleint
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Skrivanek 2013-10-23 13:59:17 UTC
Please, fix tests failing on JDK8. To reproduce:

ant -f projectuiapi test-unit -Dtest.includes=**/ProjectCustomizerListenersTest.class

http://test4u.cz.oracle.com/job/StableBTD-trunk/lastCompletedBuild/testReport
Comment 1 Milos Kleint 2013-10-24 08:35:22 UTC
any specific jdk build? for me it works locally on win7 machine.

Java: 1.8.0-ea; Java HotSpot(TM) 64-Bit Server VM 25.0-b20
Runtime: Java(TM) SE Runtime Environment 1.8.0-ea-b79
Comment 2 Jiri Skrivanek 2013-10-24 09:50:26 UTC
Java(TM) SE Runtime Environment (build 1.8.0-ea-b112)
Java HotSpot(TM) 64-Bit Server VM (build 25.0-b54, mixed mode)
Comment 3 Milos Kleint 2013-10-31 14:04:09 UTC
apparently in older versions the Close listeners were called twice and now they are called just once in latest 1.8.

I'm not clear WHY they should be called twice in the first place. Therefore if the test is covering a contract or just locks in the old, random behaviour.
Comment 4 Milos Kleint 2013-10-31 14:15:52 UTC
the stacktrace appears to be equal for both Close events recorded with earlier jdk. I've double checked the code and we only adde the listener once.

java.lang.Exception: type:CLOSE,id=testCat1
	at org.netbeans.spi.project.ui.support.ProjectCustomizerListenersTest$EventRecord.<init>(ProjectCustomizerListenersTest.java:284)
	at org.netbeans.spi.project.ui.support.ProjectCustomizerListenersTest$Listener.actionPerformed(ProjectCustomizerListenersTest.java:240)
	at org.netbeans.modules.project.uiapi.CustomizerDialog$1.windowClosed(CustomizerDialog.java:222)
	at java.awt.Window.processWindowEvent(Window.java:2054)
	at javax.swing.JDialog.processWindowEvent(JDialog.java:681)
	at java.awt.Window.processEvent(Window.java:2009)
	at java.awt.Component.dispatchEventImpl(Component.java:4861)
	at java.awt.Container.dispatchEventImpl(Container.java:2287)
	at java.awt.Window.dispatchEventImpl(Window.java:2719)
	at java.awt.Component.dispatchEvent(Component.java:4687)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:729)
	at java.awt.EventQueue.access$200(EventQueue.java:103)
	at java.awt.EventQueue$3.run(EventQueue.java:688)
	at java.awt.EventQueue$3.run(EventQueue.java:686)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.awt.EventQueue$4.run(EventQueue.java:702)
	at java.awt.EventQueue$4.run(EventQueue.java:700)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:699)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
Comment 5 Milos Kleint 2013-11-05 11:49:39 UTC
Created attachment 141863 [details]
first awt window closing event creation stacktrace
Comment 6 Milos Kleint 2013-11-05 11:50:20 UTC
Created attachment 141864 [details]
second awt window closing event creation stacktrace that only happens on jdk 1.7
Comment 7 Milos Kleint 2013-11-19 10:40:50 UTC
http://hg.netbeans.org/core-main/rev/3738ec737e48