Question: I'm trying to write a batched instrumentation test (using `ActivityInstrumentationTestCase2`) for a particular `Activity` where I change the intent each time the test runs. I can do this with a single test, and just loop through stopping and restarting the Activity with the new intent, but this is not what I want. One reason is they really should be separate test runs. The other reason is, I'm using [Spoon](https://github.com/square/spoon) to generate a report when the tests finish, and the report will rightly think I only ran one test.

What I would like is it to treat a single test as a possibly infinite number of tests, and pass the data into the test each time the test runs. 

Unfortunately you can't use [Theories](https://blogs.oracle.com/jacobc/entry/junit_theories) because it results in a RuntimeException where the InstrumentationTestRunner can't find my tests. Anyone have any luck with this?

Answer: 
I used an automation library which is [Selenium](http://docs.seleniumhq.org), which you can use in a lot of languages (C#, Java, Perl,...)

For more information how to start this link is very helpful: [this.](http://www.bitmotif.com/selenium/selenium-remote-control-for-java-a-tutorial/)
As well as Selenium, you can use <http://watin.org/>