karma-titanium-launcher currently supports testing for Apps and JS modules. Covering native modules is the last missing piece for a complete unit testing environment.
The workflow for unit testing of native modules should be as follows:
- Build the module for the current platform we are testing
- Create a temporary project serving as the test runner and integrate the built module into that project
- Run the test runner and spit out results
- Tests can be configured as usual with the Karma config. For example, tests for all platform can reside in <project-dir>/test with additional tests for each platform in the respective platform folder, i.e. <project-dir>/android/test.