Hi;
I'm trying to integration test a GWT application using ImageBundle
with WebDriver.
At one point I have images that represent various states of an object
and I need to check the correct image is being displayed.
However due to the use of ImageBundle the browser is actually seeing
something like :

img border="0" style="background: transparent url(http://localhost:
8180/aftDemo/aftDemo.gwtui.Application/
2EC9C8781E703938548B91FFE5106226.cache.png) no-repeat scroll -16px
0px; width: 16px; height: 16px; -moz-background-clip: -moz-initial; -
moz-background-origin: -moz-initial; -moz-background-inline-policy: -
moz-initial;" src="http://localhost:8180/aftDemo/
aftDemo.gwtui.Application/clear.cache.gif"

How can I decode this back into the initial images?

I tried doing GWT.create(MyImageBundle.class).my_image.getHTML() from
java but i'm not allowed to call GWT.create there  (only from client
side code or GWTUnit)

Other solutions I can imagine:
1) extract just the pixel offsets from the style attribute and
manually map these to the effective image name in the test fixture :
simple but probably quite brittle (if new images are added the offsets
are likely to change)

2) Load the composite image and perform image manipulation to extract
the displayed part and compare to the original image : seems rather
complicated and I don't want to test GWT but my code!

Any other Ideas?

Thanks;

Martin Fuzzey

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to