Does Window Test support customized components

WindowTester allows you to easily create and run unit tests for every GUI they build. It can also be used to generate system level tests.

Moderators: gnebling, Eric Clayberg, Dan Rubel, keertip, Phil Quitslund

Does Window Test support customized components

Postby keico » Fri Jan 14, 2011 11:33 am

Hello,
I'm currently working on a swing application that embeds the NASA World Wind 3D Map View (http://worldwind.arc.nasa.gov). I was wondering there's any way I can use the WindowTester Pro tool to record some of the mouse actions on the 3D World Wind map such as the Zoom action, which uses the scroll wheel on the mouse; and Tilt action, which uses the left mouse button click and drag left/right/up/down.

Can someone tell me what I need to do to achieve this goal? Your help is really appreciated!

Thank you.
keico
keico
 
Posts: 21
Joined: Wed Jan 05, 2011 7:37 am

Re: Does Window Test support customized components

Postby gnebling » Fri Jan 14, 2011 2:37 pm

We do have a ui.daragTo for Swing, but we haven't tried that with tilt action. Give it a try and let us know how it works. Unfortunately, we don't have support for mouse wheel.
gnebling
Moderator
 
Posts: 243
Joined: Tue Aug 22, 2006 7:49 am

Re: Does Window Test support customized components

Postby keico » Fri Feb 11, 2011 10:32 am

Regarding the customized component, as the test runs the tool is able locate my 3D map component. So I am able to simulate some simply actions such as a single mouse click on a map by doing this:
Code: Select all
IUIContext ui = getUI();
ui.click(new NamedWidgetLocator("World3DMap"); // I have named my customized component as  "World3DMap"


I even tries clicking on different coordinates of the map by doing this:
Code: Select all
IUIContext ui = getUI();
ui.click(new XYLocator(new NamedWidgetLocator("World3DMap"), 120, 320));
ui.click(new XYLocator(new NamedWidgetLocator("World3DMap"), 100, 100));
ui.click(new XYLocator(new NamedWidgetLocator("World3DMap"), 240, 520));


However as the test runs, it appears to me that the location of the mouse at the time the click action takes place is FIXED although I've specifically chosen different locations. Here is the sequence I observe during testing:

1. The mouse first moves to the same location on the map. This location is UNKNOWN and I speculate it's been recorded somehow by the tool.
2. The click operation takes place.
3. The mouse shows up at the new location. I believe this new location matches with the coordinates I've specified in the test code.

I was wondering if anyone might know how to simulate a mouse click action at an xy location relative to the found widget (the map in this case)?

Best regards,
-keico

p.s I also observed that other mouse actions such as double click and drag behave the same way.
keico
 
Posts: 21
Joined: Wed Jan 05, 2011 7:37 am


Return to Window Tester

Who is online

Users browsing this forum: No registered users and 1 guest

cron