In this post I will show how to test toast messages in Android using bare UI Automator.
If you are using Appium then you can skip this post, because with Appium a toast should be easily found using xpath “/hierarchy/android.widget.Toast”.
When doing mobile test automation, you might need to check if a certain notification is displayed or to get all displayed notifications. In this post I’m going to describe how this can be achieved on Android using adb and/or UiAutomator. Some of the approaches can also be used with Appium.