3

How long does robotium wait for a new activity to show up? Is it possible to set the timeout manually for the Solo instance?

Macarse
  • 91,829
  • 44
  • 175
  • 230
Vicente
  • 232
  • 1
  • 10

2 Answers2

4

What do you want that timeout for?

If you want to wait for the new activity to show up, you can use:

getInstrumentation().waitForIdleSync();

But since you are using Robotium I guess they already do that for you.

Macarse
  • 91,829
  • 44
  • 175
  • 230
  • Well, if the product code freezes, ideally, I didn't want the test code to freeze as well. It would be interesting for the test code to throw an exception if it cannot synchronize after a while. – Vicente Jun 16 '10 at 21:11
  • Oh, now I get what you are saying. I would create an issue on http://code.google.com/p/robotium/issues/list and see what the robotium's guys answer. – Macarse Jun 17 '10 at 00:56
0

If you not specify timeout manually, method solo.waitForActivity() will have default timeout 10 seconds. Because Robotium is open source project you can look it yourself by opening source code / class Waiter.

Henadzi Rabkin
  • 6,834
  • 3
  • 32
  • 39