Does anyone have any good resources for setting up Bamboo to do CI with Android projects? I have mine setup to pull source and compile it with ant. But I would love to know how to setup JUnit tests, where the tests are in a separate project.
Thanks
I have figured out how to do it using Bamboo CI and new Android Studio projects with gradle. Bamboo does not have nice drop in tasks yet but you can leverage the script runner to do it. We setup our basic build tasks as follows:
Source Code Checkout. Script task:
Then we add a final task of JUnit parser, and we use the result directory line of: **/test-results/debug/*.xml
As for testing we use Robolectric Gradle tests, which generate JUnit test results.
I hope this helps anyone else who is looking into how to setup Bamboo with Android, hopefully they will add support one day like they do for .NET where its just a single task that builds and tests. The script command feels kind of a hack.
If someone is looking for Ant style tests, I can share that too but hopefully by now everyone has moved to Android Studio from eclipse. I will say the steps required for Ant and Instrumentation take a lot more time to setup and I had to use an emulator running on the server to do the tests.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With