Forum Xamarin.Android

Testing frameworks

decriptordecriptor USBeta, Developer Group Leader Xamurai
edited October 2012 in Xamarin.Android

Is anyone out there using some form of unit testing with mfa? If so, what are the recommendations?



  • JoeJoe AUMember
    edited October 2012

    I compiled NUnitLite for MonoDroid ages ago and @wmeints wrote a runner for it. That's here, but it still requires that you deploy to a device/emulator for running the tests.

    I haven't had time to check it out in detail, but Calabash supports Android. This one actually looks really cool. Maybe someone else has some experience with it...

  • NatFriedmanNatFriedman USForum Administrator, Xamarin Team Xamurai
  • JoeJoe AUMember

    OK, I'm piqued now.
    Just installed the calabash-android gem. We'll see how this goes.

  • decriptordecriptor USBeta, Developer Group Leader Xamurai

    Thanks, I'll have to look into those.

  • WMeintsWMeints NLMember, Insider

    I saw the calabash thing the other day. If you have anything to share, please do so :-)
    I'm very interested in more testing options. NunitLite only gets you so far.

  • TomOpgenorthTomOpgenorth CAXamarin Team Xamurai

    I'd be really interested to hear how you make out with calabash as well. That looks interesting.

  • JoeJoe AUMember

    Won't have time for more playing this weekend, but I set up a skeletal test project yesterday.

    At this stage I'd say unfortunately, it's no silver bullet. You still need an emulator or device to run on, but it might prove a little easier to automate the process with a post-build script than for something like NUnitLite.

    Being able to run the tests using Cucumber is nice and the scaffold it sets up for you has a file where you can add your own custom steps (in Ruby of course).

    Will try and get something more comprehensive set up next week.

  • WMeintsWMeints NLMember, Insider

    I'm wondering if there's a way to automatically deploy the apk file to the emulator.
    I know Mono for Android has tasks to do this, so that might be a good way to go.

  • decriptordecriptor USBeta, Developer Group Leader Xamurai

    Jenkins CI server has an android plugin that launches an emulator I believe. I wonder if you can run the build through jenkins and then use the plugin to do something like that?

  • ManskiManski DEMember

    If you just need some simple unit testing framework, you can use this one:

    It's based on Visual Studio's testing framework. You need, however, to deploy to a device or the emulator.

    PS: Disclaimer. I'm the author.

Sign In or Register to comment.