Current Activity - More than one possibility.

13 views
Skip to first unread message

Guilherme Júlio

unread,
Jun 22, 2016, 12:11:59 PM6/22/16
to Robotium Developers
Hey there,

Our aplication have a menu where we can choose which activity will start next and I need to verify if the next activity will be one of them.
I'm trying to use something like this but it's no working. Could you please give me a hand?

String activity = solo.getCurrentActivity().toString();
assertTrue(activity.equals("AccountCopierActivity") ||
activity.equals("CopierFinality") ||
activity.equals("ReleaserActivity") ||
activity.equals("DocumentsActivity") ? true : false);

Thank you!

Renas

unread,
Jun 22, 2016, 12:12:44 PM6/22/16
to robotium-...@googlegroups.com
Hi, Use Solo.assertCurrentActivity or Solo.waitForActivity.

--
You received this message because you are subscribed to the Google Groups "Robotium Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to robotium-develo...@googlegroups.com.
To post to this group, send email to robotium-...@googlegroups.com.
Visit this group at https://groups.google.com/group/robotium-developers.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages