I want to write a Robotium/Junit test for an android app. At certain steps, I want my test to wait until the spinning loading symbol disappears off the screen.
How can I do that?
I want to write a Robotium/Junit test for an android app. At certain steps, I want my test to wait until the spinning loading symbol disappears off the screen.
How can I do that?
There are different ways in which you can do that. In Robotium there are a lot of different waitFor methods that you can use. In your case you can use:
solo.waitForDialogToClose() //waits for the dialog to close
solo.waitForActivity() // if there is a activity change
solo.waitForText() //if a certain text appears after the loading is done
solo.waitForView() //if a certain view is shown after the load screen is done.
Please see the Robotium API Documentation for more waitFor methods in Robotium.
© 2022 - 2024 — McMap. All rights reserved.
solo.waitForActivity(solo.getCurrentActivity().toString());
– Hexachord