Is there any way of capturing temporary popups?

Ask general questions here.
stapes
Posts: 206
Joined: Wed Sep 16, 2015 10:55 am

Is there any way of capturing temporary popups?

Post by stapes » Mon Sep 28, 2015 11:56 am

I am testing an Application, where when I try to add a record with empty fields, I see a temporary Error dialog that pops up like a tool-tip & disappears after a second or two. The developer tells me these are 'Toast' messages?

Is there any way of capturing this dialog so that I can validate its occurence?
Last edited by stapes on Mon Sep 28, 2015 12:00 pm, edited 1 time in total.

User avatar
odklizec
Ranorex Guru
Ranorex Guru
Posts: 7470
Joined: Mon Aug 13, 2012 9:54 am
Location: Zilina, Slovakia

Re: Is there any way of capturing temporary popups?

Post by odklizec » Mon Sep 28, 2015 12:00 pm

Hi,

You can use Instant Tracking feature described here:
http://www.ranorex.com/support/user-gui ... html#c3181
Of course, if the element disappears in a second or two, you will have to react quickly ;)
Pavel Kudrys
Ranorex explorer at Descartes Systems

Please add these details to your questions:
  • Ranorex Snapshot. Learn how to create one >here<
  • Ranorex xPath of problematic element(s)
  • Ranorex version
  • OS version
  • HW configuration

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Is there any way of capturing temporary popups?

Post by Support Team » Mon Sep 28, 2015 12:23 pm

Hi stapes,

Tracking toast messages on android can be very tricky since the message itself is shown only for a short amount of time. I’d suggest performing the following steps
  • Open Ranorex Spy
  • Perform an action on your device to show the Toast Message
  • Hit the refresh button in Ranorex Spy
Now you should be able to see the corresponding element in Ranorex Spy.

Hope this helps.

Regards,
Markus (S)

stapes
Posts: 206
Joined: Wed Sep 16, 2015 10:55 am

Re: Is there any way of capturing temporary popups?

Post by stapes » Mon Sep 28, 2015 12:46 pm

No, that didn't work. I decided to use a workaround here for the time being, as I can't seem to pick up the Toast message. The methods given are way too hit or miss.
Instead, I can validate that control has remained on the same screen. Had the record saved, it would have moved on to a different screen.