Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » SWTBot » How to ues the EclipseSpy view on an Application?(Seems to work on the IDE)
How to ues the EclipseSpy view on an Application? [message #1011602] Tue, 19 February 2013 21:59 Go to next message
Herb Miller is currently offline Herb MillerFriend
Messages: 22
Registered: September 2011
Junior Member
I am not sure of the "nuts and bolts" of using the SWTBot EclipseSpy view. I can get it to open, and it appears to give me information about the IDE as a move the cursor over the Eclipse IDE.

I would like to know how to use it to discover widgets on the RCP app I am trying to test. If I run the RCP App, and if I hover over Widgets in the RCP app, I get no results showing up in the EclipseSpy View. It seems that knowing about the widgets of the app I want to test is more important than the widgets in the Eclipse IDE.

Do I need to include the EclipseSpy as a dependency for my app under test? Do I need to embed something in the app to make it EclipseSpy aware?

Just a quick "How-To" for button pushes on using the EclipseSpy View would be helpful. I am using Indigo (3.7) and one of the latest SWTBot downloads.

My simple SWTBot test seems to work fine, but I need to know how to use the EclipseSpy View.

Thanks,
Herb Miller
Re: How to ues the EclipseSpy view on an Application? [message #1011911 is a reply to message #1011602] Wed, 20 February 2013 13:36 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

Hi,
To be honest, I'm not aware of anyone who even tried to embed EclipseSpy
in another RCP than Eclipse IDE.
I think that's worth opening a bug. Do you think you could create a test
case to test EclipseSpy?

--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria
Re: How to ues the EclipseSpy view on an Application? [message #1011940 is a reply to message #1011911] Wed, 20 February 2013 14:47 Go to previous messageGo to next message
Herb Miller is currently offline Herb MillerFriend
Messages: 22
Registered: September 2011
Junior Member
My problem is that I do not know how to use EclipseSpy. If someone can tell me how to use it, I would be grateful. Surely it is not just for hovering over the Eclipse IDE?

For years, Visual Studio has had a tool called something-Spy (not sure of the name). You could use this tool to see the activity of almost any GUI widget that was displayed on the desktop. I assumed that EclipseSpy has this functionality, and I just do not know how to use it correctly.

Is it really only intended for the Eclipse IDE?

Thanks.
Re: How to ues the EclipseSpy view on an Application? [message #1012024 is a reply to message #1011940] Wed, 20 February 2013 18:06 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

On 02/20/2013 03:47 PM, Herb Miller wrote:
> My problem is that I do not know how to use EclipseSpy. If someone can
> tell me how to use it, I would be grateful. Surely it is not just for
> hovering over the Eclipse IDE?

I've never even looked at the EclipseSpy code but I guess it listen to
mouse move and get the control under the mouse and change the content
when it's a new control.
If it works with the IDE, I think it could work with any RCP
application: just install the plugin in your RCP app, open the
EclipseSpy view, and it should be all. If it's not working, it's most
likely a bug.

> For years, Visual Studio has had a tool called something-Spy (not sure
> of the name). You could use this tool to see the activity of almost any
> GUI widget that was displayed on the desktop. I assumed that EclipseSpy
> has this functionality, and I just do not know how to use it correctly.

The EclipseSpy is only intended to SWTBot UI, and most likely only
"spies on" the application that hosts it.

HTH
--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria
Re: How to ues the EclipseSpy view on an Application? [message #1012114 is a reply to message #1012024] Wed, 20 February 2013 22:36 Go to previous messageGo to next message
Herb Miller is currently offline Herb MillerFriend
Messages: 22
Registered: September 2011
Junior Member
I do have an RCP application that uses a lot more of the eclipse plugins (ide, etc). On this app, what you suggested worked. The Menu->Window option was available, and I was able to open the EclipseSpy view and it worked for the app.

Now all I have to do is figure out the dependencies for the EclipseSpy view, and I should be able to plug this into any RCP app temporarily to find out information about the widgets.

If you know the dependencies, please let me know.

Thanks again.
Re: How to ues the EclipseSpy view on an Application? [message #1012863 is a reply to message #1012114] Fri, 22 February 2013 10:56 Go to previous messageGo to next message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

If you install with p2, then you don't have to worry about dependencies.
OTherwise, just look at the MANIFEST.MF:
http://git.eclipse.org/c/swtbot/org.eclipse.swtbot.git/tree/org.eclipse.swtbot.eclipse.spy/META-INF/MANIFEST.MF

--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria
Re: How to ues the EclipseSpy view on an Application? [message #1014508 is a reply to message #1012863] Tue, 26 February 2013 00:17 Go to previous message
Herb Miller is currently offline Herb MillerFriend
Messages: 22
Registered: September 2011
Junior Member
Thanks. I will try to get the EclipseSpy into my project so I can use to find some of the escoteric GUI combinations added by the programmers - like a Form with a Section with a formatted Text box tied to a toolbar with toolitems and menus and menuitems made up of formatted text boxes.
Previous Topic:Error/Exception handling using SWTBot .
Next Topic:How to find Toolbar and ToolItems with SWTBot
Goto Forum:
  


Current Time: Sat Apr 20 02:16:07 GMT 2024

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

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

Back to the top