With the latest releases of the ConnectIQ SDK, it is finally easy to run the SDK on Linux. Thanks to this update, I've been able to create a Docker image that tests a ConnectIQ application (if it uses "Run No Evil"). The command to test an app is:
docker run -v /path/to/your/app:/app -w /app ghcr.io/matco/connectiq-tester:latest fenix7
The code source of the image is available here: https://github.com/matco/connectiq-tester. It's currently based on ConnectIQ 4.1.4 and the device bits retrieved on 29 June 2022.
In addition to the Docker image, I created a GitHub Actions that can test your application using GitHub CI. Just add the following step to your GitHub workflow:
- name: Test application id: run_tests uses: matco/action-connectiq-tester@v1 with: device: fenix7
The web page of the action is here: https://github.com/marketplace/actions/connectiq-tester and its source code is here: https://github.com/matco/action-connectiq-tester. You can have a look at the CI workflow of my own ConnectIQ application here: https://github.com/matco/badminton/blob/dev/.github/workflows/test.yml.
Feel free to use these tools and do not hesitate to provide your feedback. I already have ideas to improve them. My goal was to have the simplest GitHub Action possible, but I'm not sure if this approach is the good one. It may be better to have an action that setups ConnectIQ directly in the GitHub Action runner. This would allow choosing the version of the SDK to install and give more flexibility to the Action (for example, choosing custom flags for the compiler).
I found that someone built a Docker image that setups the full ConnectIQ SDK here: https://github.com/cedric-dufour/connectiq-sdk-docker. It's funny because the Docker files are very similar, even if the goal is slightly different. This image could be a good base for another kind of GitHub Action.
I also have a message for the Garmin ConnectIQ team: it's still far too complicated to retrieve and set up the device files that are required to launch the simulator. A direct download link to these files would be good. An option to configure the path of the devices bits would also be appreciated (instead of hard-coding a path inside the user's home folder).
I also think it would be nice if Garmin provides and supports these kind of tools themselves. By the way, both the Docker image and the GitHub Action are licensed with the "unlicense" (public domain) so you can do whatever you want with them. I would be happy if you decide to copy and support them as your own.