0

I have created an android test project which I run using Eclipse. However, I need to run it on hourly basis and I was thinking if I could schedule this thing.

Scenario is that AUT is installed on my device. Everytime I need to run the automated test project, I connect it to my computer and 'run as Android Test'. I don't have to create any more test cases and I know that test project do remain installed over the device.

Is there a way I could create a cron job over my device so that I could schedule this testing? I know how to write Quartz Scheduler in java and have run it through Tomcat but am new to android.

Can someone suggest some solution if exists or some workaround? Thanks.

roger_that
  • 9,493
  • 18
  • 66
  • 102
  • May be you can create another application that will trigger your test application after every n minute. That application will run as a background service. Take a look at http://stackoverflow.com/questions/16155032/android-running-a-background-task-every-15-minutes-even-when-application-is-n to understand how can it work. – Ritesh Waghela Apr 29 '14 at 09:39
  • Google about Android background services. They will help – narek.gevorgyan Apr 29 '14 at 09:39
  • I created another application(say A) with an activity and tried to launch the test application(say B) via button tap, but as i tap my application A crashes saying it cannot find the test project package. – roger_that Apr 29 '14 at 09:53
  • I would use CI (Jenkins) to build and run tests instead of plain cron. There's an introduction to CI & Android presented at http://dtmilano.blogspot.ca/2013/11/android-continuous-integration-guides.html – Diego Torres Milano Apr 30 '14 at 15:19

0 Answers0