Skip to main content



      Home
Home » Eclipse Projects » RCP Testing Tool » RCPTT and nebula grid
RCPTT and nebula grid [message #1709253] Fri, 25 September 2015 06:08 Go to next message
Eclipse UserFriend
I am just getting started with RCPTT and trying to see if it can cover our use cases. I have an RCP application which makes heavy use of the Nebula Grid widget and I am having some trouble interacting with it.

For a standard TreeViewer part I can do something like;

get-tree | get-item "Item-Name" | select-item | get-menu "Context Menu Item Name" |click


to open the context menu with the selected item. How can I do the same with the Nebula Grid?

I have tried the following but this does gives an error message saying it is not a tree or table item.

get-nebula-grid | get-item "Cell Item Name" | select-item


Is this the correct usage? Is there an alternative set of methods? Is there a specific version of nebula grid that should be used?

I am also looking to be able to select a specific cell. E.g. I can do this;

get-nebula-grid | get-item "Item Name" | get-item-cell -column "Column Name"


However in some of my views I have multiple columns with the same name. Is it possible to distinguish between them? Is this something that I would need to build some custom ECL hooks for?

Finally how does get-item work? Is it looking at just the first column? Is it possible to search a specific column for a value?

Thanks,

SImon
Re: RCPTT and nebula grid [message #1709402 is a reply to message #1709253] Mon, 28 September 2015 05:16 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Have you tried to record actions in nebula grid widget? What was the result?
Could you please attach the generated ECL snippet?
For me the following snippet works well:
    
    with [get-nebula-grid] {
        select "" | activate-cell-edit // select the first empty row in the first column and start editing
        get-editbox | type-text 1 // type "1" into the cell
        apply-cell-edit -deactivate // apply editing
        select 1 | activate-cell-edit -column 1 // select the first row with "1" and activate editing of the second column
    }

You may use the key -index to find needed row (get-item "Name" -index 3), if there are multiple identical rows, and the key -column (as I use in the 5th line) to identify needed column.
Please try and let me know if it is helpful.

You can find more information about get-item here and about get-item-cell there.
Re: RCPTT and nebula grid [message #1710343 is a reply to message #1709402] Tue, 06 October 2015 03:55 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Very helpful thanks. However I have only been able to select rows based on the value in the first column. Is there a way to select rows based on values in other columns? I tried adding -index/-column arguments to select but it is unable to find anything.

I have tried recording actions but nothing is recorded at all, regardless of whether it is a nebula control or not.

Simon
Re: RCPTT and nebula grid [message #1710407 is a reply to message #1710343] Tue, 06 October 2015 09:04 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Unfortunately it doesn't work now in Nebula Grid, I've created a bug about it in bugzilla.
I'll notify you about progress, but for now it has low priority.
How critical is this feature for you?

As for nothing is recorded, could you please attach widget details (how to get it)?
Re: RCPTT and nebula grid [message #1713997 is a reply to message #1710407] Mon, 09 November 2015 05:45 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Sorry for the delay, something else came up with higher priority.

We have a large number of tables based around the nebula grid and need to be interacted with. However with are also just starting to look at NAT table - I see you guys are working on support for this?

Regarding the test recording, I see the red target markers appear in my application. However the assertions window does not appear.

I have my (e4 based) rcp application launching and the test cases interact with it. I have created a new test case and pressed the "record" button. Rcptt minimised and the control panel window appears. However no interaction is recorded.

Are there any settings or otherwise I should be checking?

[Updated on: Mon, 09 November 2015 05:46] by Moderator

Re: RCPTT and nebula grid [message #1714010 is a reply to message #1713997] Mon, 09 November 2015 06:47 Go to previous message
Eclipse UserFriend
I have found some exceptions in my application error log when attempting to start a recording. These two are generated from just clicking once to bring the error log view to the top.

ava.lang.NullPointerException
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.createElementEntry(SWTWidgetLocator.java:767)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.selectRequiredElementToBeFocused(SWTWidgetLocator.java:725)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findGenericElement(SWTWidgetLocator.java:685)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findElement(SWTWidgetLocator.java:299)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findElement(SWTWidgetLocator.java:1450)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.processTabFolder(SWTEventRecorder.java:1310)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.processSelection(SWTEventRecorder.java:1214)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.recordEvent_(SWTEventRecorder.java:595)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.recordEvent(SWTEventRecorder.java:454)
	at org.eclipse.rcptt.tesla.recording.aspects.SWTEventManager.recordEvent(SWTEventManager.java:112)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$1$bd9fb3e7(RecordingAspect.aj:75)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1074)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1070)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:782)
	at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:3110)
	at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1794)
	at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:283)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4353)
	at org.eclipse.swt.widgets.Widget.sendEvent_aroundBody2(Widget.java:1061)
	at org.eclipse.swt.widgets.Widget$AjcClosure3.run(Widget.java:1)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$2$2f127892proceed(RecordingAspect.aj:1)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$2$2f127892(RecordingAspect.aj:118)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1059)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4172)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3761)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1151)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1032)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:636)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:579)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
	at com.mmxlabs.lingo.app.intro.Application.start(Application.java:85)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1465)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1438)



and

java.lang.AssertionError: The feature 'element' is not a valid feature
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eDerivedStructuralFeatureID(BasicEObjectImpl.java:1500)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:1008)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:1003)
	at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:998)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.FeaturePredicate.getFeature(FeaturePredicate.java:52)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.FeaturesEqPredicate.apply(FeaturesEqPredicate.java:26)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.TwoCommandsPredicate.apply(TwoCommandsPredicate.java:23)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.TwoCommandsPredicate.apply(TwoCommandsPredicate.java:1)
	at org.eclipse.rcptt.util.Predicates$2.apply(Predicates.java:26)
	at org.eclipse.rcptt.util.Predicates$2.apply(Predicates.java:26)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.CommandsPredicate.apply(CommandsPredicate.java:37)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.CommandsPredicate.apply(CommandsPredicate.java:1)
	at org.eclipse.rcptt.util.Predicates$2.apply(Predicates.java:26)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.MatcherProcessingRule.matches(MatcherProcessingRule.java:64)
	at org.eclipse.rcptt.tesla.recording.core.swt.peg.CommandPostProcessor.recordCommand(CommandPostProcessor.java:101)
	at org.eclipse.rcptt.tesla.recording.core.TeslaRecorder.hookExecuteCommand(TeslaRecorder.java:85)
	at org.eclipse.rcptt.tesla.recording.core.BaseTeslaRecorder.executeCommand(BaseTeslaRecorder.java:196)
	at org.eclipse.rcptt.tesla.core.protocol.UIPlayer.safeExecuteCommand(UIPlayer.java:91)
	at org.eclipse.rcptt.tesla.core.protocol.UISelector.find(UISelector.java:206)
	at org.eclipse.rcptt.tesla.core.protocol.UISelector.find(UISelector.java:171)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.createElementEntry(SWTWidgetLocator.java:766)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.selectRequiredElementToBeFocused(SWTWidgetLocator.java:725)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findGenericElement(SWTWidgetLocator.java:685)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findElement(SWTWidgetLocator.java:299)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTWidgetLocator.findElement(SWTWidgetLocator.java:1450)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.processTabFolder(SWTEventRecorder.java:1310)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.processSelection(SWTEventRecorder.java:1214)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.recordEvent_(SWTEventRecorder.java:595)
	at org.eclipse.rcptt.tesla.recording.core.swt.SWTEventRecorder.recordEvent(SWTEventRecorder.java:454)
	at org.eclipse.rcptt.tesla.recording.aspects.SWTEventManager.recordEvent(SWTEventManager.java:112)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$1$bd9fb3e7(RecordingAspect.aj:75)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1074)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1070)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:782)
	at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:3110)
	at org.eclipse.swt.custom.CTabFolder.onMouse(CTabFolder.java:1794)
	at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:283)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4353)
	at org.eclipse.swt.widgets.Widget.sendEvent_aroundBody2(Widget.java:1061)
	at org.eclipse.swt.widgets.Widget$AjcClosure3.run(Widget.java:1)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$2$2f127892proceed(RecordingAspect.aj:1)
	at org.eclipse.rcptt.tesla.recording.aspects.RecordingAspect.ajc$around$org_eclipse_rcptt_tesla_recording_aspects_RecordingAspect$2$2f127892(RecordingAspect.aj:118)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1059)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4172)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3761)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1151)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1032)
	at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:636)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:579)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
	at com.mmxlabs.lingo.app.intro.Application.start(Application.java:85)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1465)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1438)
Previous Topic:Right click action does not work
Next Topic:[SOLVED] base_dir in Linux
Goto Forum:
  


Current Time: Sun Jun 22 21:16:57 EDT 2025

Powered by FUDForum. Page generated in 0.43898 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top