I am testing an Android app with Appium (Java Client), with no access to the code. I am checking if, after having clicked a button, a short-length Toast is displayed. I am trying to get the screenshot of the toast to read it with Tess4J, but I can not capture it.
I tried taking a series of screenshots in a different Thread, but the screenshots are taken before the click() or after the click() on the button, never during the click(). The click() petition lasts 2-3 seconds, just the time the Toast is on the screen. I can confirm this because I get the time each screenshot is taken.
I tested on other long-length toasts of the same app and I have no problem to capture them. But it is impossible to me to capture this short-length Toast.
Is there a way to do it, or is it a limitation of Appium server? I read the server logs, and the click() petition is placed among the different getScreenshot() petitions. I think the problem is that click() and getScreenshot() can not be performed simultaneously, so the screenshot are taken before and after the click(), just the time the Toast is on screen.
Thank you very much for any help you can provide