Failed to create widget reference for instance of org.eclipse.swt.widgets.Menu WindowTester: 201108222321 - win32, win32, x86

216 views
Skip to first unread message

dayson

unread,
Mar 1, 2012, 10:22:22 AM3/1/12
to windowtester-pro
The following environment was used:
* Eclipse 3.7.1 x64 (Where test plugins live and will launch a target
installation)
* WindowTester - http://dl.google.com/eclipse/inst/windowtester/beta/3.7
* Windows 7 x64
* Application under test was written for Eclipse 3.7.1 x86

In the past I have been using a 32-bit version of Eclipse 3.7.1 and
dropping our applications features and plugins into the 32-bit eclipse
dropins folder. The WindowTester tests are then run as a JUnit Plug-in
test and ensuring in the launch configuration that we Run a project
(com.my.app.ide). This works fine when executing manually. Though,
trying to launch them from command line results in the issue posted
here: http://groups.google.com/group/windowtester-pro/browse_thread/thread/e90e0ae9d5b34185
(java.lang.NullPointerException at
org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication .java:
112)).

In order to find a workaround to this issue that hasn't been resolved
(I know plenty of people have been trying to launch from command line)
I wanted to try it on a 64-bit version of eclipse and instead of
dropping our applications features and plugins in I elected to point
eclipse to Target the installation platform of our application. So a
similar launch configuration was made and the resulting stack trace
can be found in the JUnit view:

Caused by: java.lang.RuntimeException: Failed to create widget
reference for instance of org.eclipse.swt.widgets.Menu
WindowTester: 201108222321 - win32,win32,x86
at
com.windowtester.runtime.internal.factory.WTRuntimeManager.createReference(WTRuntimeManager.java:
95)
at
com.windowtester.runtime.internal.factory.WTRuntimeManager.asReference(WTRuntimeManager.java:
36)
at
com.windowtester.runtime.swt.internal.widgets.SWTWidgetReference.asReferenceOfType(SWTWidgetReference.java:
262)
at com.windowtester.runtime.swt.internal.widgets.DecorationsReference
$2.call(DecorationsReference.java:34)
at com.windowtester.runtime.swt.internal.widgets.DecorationsReference
$2.call(DecorationsReference.java:1)
at
com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor.execute(SWTUIExecutor.java:
132)
at com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor.access
$0(SWTUIExecutor.java:130)
at com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor
$1.run(SWTUIExecutor.java:91)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:
135)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:
4140)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)
at
com.windowtester.runtime.swt.internal.junit.SWTExecutionMonitor.doWaitForFinish(SWTExecutionMonitor.java:
151)
at
com.windowtester.internal.runtime.junit.core.AbstractExecutionMonitor.waitUntilFinished(AbstractExecutionMonitor.java:
205)
at
com.windowtester.internal.runtime.junit.core.SequenceRunner.waitUntilFinished(SequenceRunner.java:
69)
at
com.windowtester.internal.runtime.junit.core.SequenceRunner.exec(SequenceRunner.java:
53)
at
com.windowtester.runtime.common.UITestCaseCommon.runUITest(UITestCaseCommon.java:
147)
at
com.windowtester.runtime.common.UITestCaseCommon.runBare(UITestCaseCommon.java:
128)
at junit.framework.TestResult$1.protect(TestResult.java:110)
at junit.framework.TestResult.runProtected(TestResult.java:128)
at junit.framework.TestResult.run(TestResult.java:113)
at junit.framework.TestCase.run(TestCase.java:124)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at junit.framework.TestSuite.runTest(TestSuite.java:243)
at junit.framework.TestSuite.run(TestSuite.java:238)
at
org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:
83)
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:
50)
at
org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:
38)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:
467)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:
683)
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:
390)
at
org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePluginTestRunner.java:
62)
at org.eclipse.pde.internal.junit.runtime.PlatformUITestHarness
$1.run(PlatformUITestHarness.java:47)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:
135)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:
4140)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:
2696)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2660)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2494)
at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:674)
at
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:
332)
at
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:
667)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:
149)
at
org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:
123)
at
org.eclipse.pde.internal.junit.runtime.NonUIThreadTestApplication.runApp(NonUIThreadTestApplication.java:
54)
at
org.eclipse.pde.internal.junit.runtime.UITestApplication.runApp(UITestApplication.java:
41)
at
org.eclipse.pde.internal.junit.runtime.NonUIThreadTestApplication.start(NonUIThreadTestApplication.java:
48)
at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:
196)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:
110)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:
79)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:
344)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:
179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
at org.eclipse.equinox.launcher.Main.main(Main.java:1386)

Any insight on how to resolve this would be greatly appreciated.
Thanks in advanced!

Dan

Keerti Parthasarathy

unread,
Mar 1, 2012, 11:32:50 AM3/1/12
to windowte...@googlegroups.com
Dan,

On the 64bit environment, did you run the tests manually? Is that when you see this exception?

--
Keerti

dayson

unread,
Mar 1, 2012, 11:41:10 AM3/1/12
to windowtester-pro
Thanks so much for the quick response!

The error occurs on the following environment:
* Eclipse 3.7.1 x64
* Windows 7 x64

Yes, I was trying to launch these test manually from within Eclipse
3.7.1 x64 when targetting our 32-bit application installation. I hope
this is the information you are looking for...

On 1 Mar, 11:32, Keerti Parthasarathy <keer...@google.com> wrote:
> Dan,
>
> On the 64bit environment, did you run the tests manually? Is that when you
> see this exception?
>
>
>
>
>
>
>
>
>
> On Thu, Mar 1, 2012 at 7:22 AM, dayson <danielay...@gmail.com> wrote:
> > The following environment was used:
> > * Eclipse 3.7.1 x64 (Where test plugins live and will launch a target
> > installation)
> > * WindowTester -http://dl.google.com/eclipse/inst/windowtester/beta/3.7
> > * Windows 7 x64
> > * Application under test was written for Eclipse 3.7.1 x86
>
> > In the past I have been using a 32-bit version of Eclipse 3.7.1 and
> > dropping our applications features and plugins into the 32-bit eclipse
> > dropins folder. The WindowTester tests are then run as a JUnit Plug-in
> > test and ensuring in the launch configuration that we Run a project
> > (com.my.app.ide). This works fine when executing manually. Though,
> > trying to launch them from command line results in the issue posted
> > here:
> >http://groups.google.com/group/windowtester-pro/browse_thread/thread/...

dayson

unread,
Mar 1, 2012, 11:55:04 AM3/1/12
to windowtester-pro
I should also point out that the workspace in 32-bit eclipse does not
show this exception and running the same workspace in the 64-bit
version throws these exceptions.

On 1 Mar, 11:32, Keerti Parthasarathy <keer...@google.com> wrote:
> Dan,
>
> On the 64bit environment, did you run the tests manually? Is that when you
> see this exception?
>
>
>
>
>
>
>
>
>
> On Thu, Mar 1, 2012 at 7:22 AM, dayson <danielay...@gmail.com> wrote:
> > The following environment was used:
> > * Eclipse 3.7.1 x64 (Where test plugins live and will launch a target
> > installation)
> > * WindowTester -http://dl.google.com/eclipse/inst/windowtester/beta/3.7
> > * Windows 7 x64
> > * Application under test was written for Eclipse 3.7.1 x86
>
> > In the past I have been using a 32-bit version of Eclipse 3.7.1 and
> > dropping our applications features and plugins into the 32-bit eclipse
> > dropins folder. The WindowTester tests are then run as a JUnit Plug-in
> > test and ensuring in the launch configuration that we Run a project
> > (com.my.app.ide). This works fine when executing manually. Though,
> > trying to launch them from command line results in the issue posted
> > here:
> >http://groups.google.com/group/windowtester-pro/browse_thread/thread/...
> > (java.lang.NullPointerException at
> > org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication
> > .java:
> > 112)).
>
> > In order to find a workaround to this issue that hasn't been resolved
> > (I know plenty of people have been trying to launch from command line)
> > I wanted to try it on a 64-bit version of eclipse and instead of
> > dropping our applications features and plugins in I elected to point
> > eclipse to Target the installation platform of our application. So a
> > similar launch configuration was made and the resulting stack trace
> > can be found in the JUnit view:
>
> > Caused by: java.lang.RuntimeException: Failed to create widget
> > reference for instance of org.eclipse.swt.widgets.Menu
> >   WindowTester: 201108222321 - win32,win32,x86
> >        at
>
> > com.windowtester.runtime.internal.factory.WTRuntimeManager.createReference( WTRuntimeManager.java:
> > 95)
> >        at
>
> > com.windowtester.runtime.internal.factory.WTRuntimeManager.asReference(WTRu ntimeManager.java:
> > 36)
> >        at
>
> > com.windowtester.runtime.swt.internal.widgets.SWTWidgetReference.asReferenc eOfType(SWTWidgetReference.java:
> > 262)
> >        at
> > com.windowtester.runtime.swt.internal.widgets.DecorationsReference
> > $2.call(DecorationsReference.java:34)
> >        at
> > com.windowtester.runtime.swt.internal.widgets.DecorationsReference
> > $2.call(DecorationsReference.java:1)
> >        at
>
> > com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor.execute(SWTUIEx ecutor.java:
> > 132)
> >        at
> > com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor.access
> > $0(SWTUIExecutor.java:130)
> >        at com.windowtester.runtime.swt.internal.widgets.SWTUIExecutor
> > $1.run(SWTUIExecutor.java:91)
> >        at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
> >        at
> > org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:
> > 135)
> >        at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:
> > 4140)
> >        at
> > org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3757)
> >        at
>
> > com.windowtester.runtime.swt.internal.junit.SWTExecutionMonitor.doWaitForFi nish(SWTExecutionMonitor.java:
> > 151)
> >        at
>
> > com.windowtester.internal.runtime.junit.core.AbstractExecutionMonitor.waitU ntilFinished(AbstractExecutionMonitor.java:
> > 205)
> >        at
>
> > com.windowtester.internal.runtime.junit.core.SequenceRunner.waitUntilFinish ed(SequenceRunner.java:
> > 69)
> >        at
>
> > com.windowtester.internal.runtime.junit.core.SequenceRunner.exec(SequenceRu nner.java:
> > 53)
> >        at
>
> > com.windowtester.runtime.common.UITestCaseCommon.runUITest(UITestCaseCommon .java:
> > 147)
> >        at
>
> > com.windowtester.runtime.common.UITestCaseCommon.runBare(UITestCaseCommon.j ava:
> > 128)
> >        at junit.framework.TestResult$1.protect(TestResult.java:110)
> >        at junit.framework.TestResult.runProtected(TestResult.java:128)
> >        at junit.framework.TestResult.run(TestResult.java:113)
> >        at junit.framework.TestCase.run(TestCase.java:124)
> >        at junit.framework.TestSuite.runTest(TestSuite.java:243)
> >        at junit.framework.TestSuite.run(TestSuite.java:238)
> >        at junit.framework.TestSuite.runTest(TestSuite.java:243)
> >        at junit.framework.TestSuite.run(TestSuite.java:238)
> >        at
> > org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:
> > 83)
> >        at
>
> > org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestRe ference.java:
> > 50)
> >        at
> > org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:
> > 38)
> >        at
>
> > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestR unner.java:
> > 467)
> >        at
>
> > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestR unner.java:
> > 683)
> >        at
>
> > org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner .java:
> > 390)
> >        at
>
> > org.eclipse.pde.internal.junit.runtime.RemotePluginTestRunner.main(RemotePl uginTestRunner.java:
> > org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication .java:
> > 123)
> >        at
>
> > org.eclipse.pde.internal.junit.runtime.NonUIThreadTestApplication.runApp(No nUIThreadTestApplication.java:
> > 54)
> >        at
>
> > org.eclipse.pde.internal.junit.runtime.UITestApplication.runApp(UITestAppli cation.java:
> > 41)
> >        at
>
> > org.eclipse.pde.internal.junit.runtime.NonUIThreadTestApplication.start(Non UIThreadTestApplication.java:
> > 48)
> >        at
>
> > org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java :
> > 196)
> >        at
>
> > org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication (EclipseAppLauncher.java:
> > 110)
> >        at
>
> > org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseA ppLauncher.java:

dayson

unread,
Mar 6, 2012, 1:06:12 PM3/6/12
to windowtester-pro
Anything?

Keerti Parthasarathy

unread,
Mar 6, 2012, 1:28:30 PM3/6/12
to windowte...@googlegroups.com
It looks like Windowtester does not handle 64bit very well - at least for some widgets. This is not a small fix, so will take some time.
--
Keerti

Dan Ayson

unread,
Mar 6, 2012, 2:39:59 PM3/6/12
to windowte...@googlegroups.com
Great, thanks! I will be monitoring this thread waiting for a response when fix is ready.


Having a fix for that would be greater than the one for 64-bit eclipse. 

keerthivasan chinnathambi

unread,
Feb 20, 2015, 5:19:14 AM2/20/15
to windowte...@googlegroups.com

Hello keerti,

Any update on the topic ?

Please find my environment details.

Windows : 64 bit environment
Eclipse Kepler(4.3.2), 64 bit
WindowTester : 6.1.0 ( contains plugins of com.windowtester.swt.runtime.
win32.win32.x86_64_6.1.0.201310072244,com.windowtester.swt.runtime.win32.win32.x86_6.1.0.201310072244 and com.windowtester.swt.runtime_6.1.0.201310072244)
Java_ JRE(1.7) : 64 bit

It has been blocker for me.

Could you please help me in resolving the same ?

Thank you,
Keerthi

Reply all
Reply to author
Forward
0 new messages