How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1012552/#msg_1012552
The application that i am testing has certain text fields where validations are set.
for eg : There is textWithLabel("UserId *") which cannot have length more that 15 characters.
My tests run fine for all positive values but when i try negative scenarios it fails.
Is there any way where I can capture the error message in some SWTBot object whenever it fails.
The error message is a Text in Red Color displayed on the application panel.

]]>ajay shedge2013-02-21T19:30:15-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1012870/#msg_1012870
--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria]]>Mickael Istria2013-02-22T11:06:54-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1013061/#msg_1013061
I have attached the required screenshot.
I want to know how to handle the validations of fields seen in the screenshot.
I have certain cases where I intentionally insert such values in these fields which should generate error. I need to capture this error message using SWTBot.

I also tried to search for the repository of SWTGenerator (http://download.eclipse.org/technology/swtbot/snapshots/) but somehow its not working.
Will you also direct me to appropriate link from where i can download and start using it.]]>ajay shedge2013-02-22T17:36:43-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1014285/#msg_1014285
> Hi Mickael,
> I have attached the required snapshot.
> I want to know how to handle the validations of fields seen in the snapshot.
> I have certain cases where I intentionally insert such values in these fields which should generate error. I need to capture this error message using SWTBot.

I don't know of anything in SWTBot that allows you to check the message
of a Wizard. I guess you'll need to use underlying SWT widgets and API
to check what you want here.

What do you mean by "it is not working"? In this world of ours "not
working" doesn't mean much.
Can you go into details: what did you try? What worked? What did you
expect? What did you got?
--
Mickael Istria
JBoss, by Red Hat
My blog: http://mickaelistria.wordpress.com
My Tweets: http://twitter.com/mickaelistria]]>Mickael Istria2013-02-25T14:16:10-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1014350/#msg_1014350
Indeed getting the (error/warning) Label and message Text displayed in a wizard is not as easy as it would seem at first.

I did encapsulate the corresponding code in my own API built on top of SWTBot.
It seems to be working OK (so far). You could try adapting it your specific case.

Hope this helps,]]>Benjamin Ratiarisolo2013-02-25T16:33:44-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1014856/#msg_1014856
ajay shedge2013-02-26T15:46:06-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1014858/#msg_1014858
I was not able to locate the repository (http://download.eclipse.org/technology/swtbot/snapshots/) for installing the SWTbot Recorder and Test Generator.
The link is broken and I did not know from where to find the latest repository. Hence i had raised this question in this topic.
]]>ajay shedge2013-02-26T15:51:11-00:00Re: How to capture error messages thrown by an Eclipse application using SWTBot ?https://www.eclipse.org/forums/index.php/mv/msg/455762/1014893/#msg_1014893
http://download.eclipse.org/technology/swtbot/snapshots/content.jar
If you can't access this file, it means that you have a problem on your
side.