Verifying Text Image on a screen

I am new to eggplant. After executing a menu choice a list will show up on the right of the GUI. I want to verify that all the expected text values are correct. I am trying to capture each string as an image and then trying to compare that image.

I captured the image and saved it.
I am trying to use the Use Image --> ImageFound command.

Not working. :x

[quote=“gman”]I am new to eggplant. After executing a menu choice a list will show up on the right of the GUI. I want to verify that all the expected text values are correct. I am trying to capture each string as an image and then trying to compare that image.

I captured the image and saved it.
I am trying to use the Use Image --> ImageFound command.

Not working. :x[/quote]

Well, can you use the ImageDoctor (Images Tab of the Suite Window) to see if the image can indeed be found on screen. There are also some tips here. Let us know if any of the suggested in the linked post don’t point you in the right direction.

Allen

Bear in mind that ImageFound() is a function and needs to be used as part of a statement. Generally, ImageFound() is used in a conditional statement such as

if imageFound("someImage")
     -- do something
end if

Putting the ImageFound() function on a line by itself won’t do anything.

I should also mention that while the “Use Image” feature allows you to insert an existing image in an ImageFound() function, it requires additional manual editing of the script to put that code into a statement as shown above. It’s a convenience feature that is designed to assist the user, but Eggplant can’t know how you want to use the result of that function.

…now I am trying to capture a Text Image. I get the following error;

Error Generating Text Image – Unable to Contact Server: aur-rmetest01:5899 (Connection refused)

Close the Text Image Preview above to allow saving command anyway.

So I go to the remote computer and change the VNC Server settings to

“Serve Java viewer on port” 5899

I try generating the Text Image again and get the following error;

Error Generating Text Image – Error: ‘Connection timed out’ while reading Image Info size from Server (aur-rmetest01:5899)
Close the Text Image Preview above to allow saving command anyway.

Any ideas?

If you’re running against a Windows machine, you have to have the Windows TIG (Text Image Generator) running on that box. That’s available under the downloads tab above. You should change the port back on the VNC Java server to 5800. The TIG runs on 5899 by default (although that too is configurable).

The TIG is a separate program that runs on port 5899, and on a Windows SUT you should have this run on start-up, and make sure the Windows firewall is allowing the TIG and VNC, or ports 5899 and 5900, though it.

v