Github Action for CI IronPython in Rhino

Hello there!

I have a small Rhino plugin composed of various Python scripts wrapped in commands and called by the user in Rhino. So far so good. What I would like to do is to put up a CI workflow in GitHub to run tests on my python rhino scripts and smoke/mock testing them against possible malfunctioning when running on Rhino.

I was curious to know if there are some GitHub Actions out there that could e.g. run a headless Rhino .exe (or even Rhino.compute or a RhinoCommons NuGet) on the GitHub server to test those scripts.

Thank you in advance for any possible hints! :pray::pray:

Hey @andrea.settimi ,

It’s possible, if a bit tricky.
You’ll need to be running a Windows base VM, install rhino, license it and then you can run some tests.

When I’ve used GitHub in the past I’ve done it all on a local hosted machine, which is a pain long term to maintain, but easier short term to get working.


For Crash I use CircleCI and I created this Orb to create a Rhino installed VM. (I have to make this public on CircleCI, it’s on my To-do pile, let me know if you’re interested and I can do it sooner rather than later)

And then for Unit Tests I created this NUnit Resolver

And I string them together like this

And that’s worked pretty well for me.

– cs

4 Likes

Hello @csykes ! Thanks for the detailed answer and all the insights into crash (love the work btw). Indeed having a VM with Rhino seems to be reasonable. I wonder if it would be easier if there is a Docker image with Rhino (or only RhinoCompute) installed and a token for the licensing that could be simply pulled by the DockerHub with a vanilla GitHub action and run a headless version. In any case I would be curious to have a look at your CircleCI implementation, at your own pace of course and thanks for your insightful reply !

1 Like

It’s a good question. I’ll have time in the next few weeks and I’ll have a go at the docker idea. Let me know if you give it a shot! I know there’s one for Rhino Compute. I’ve been meaning to publish all these bits and bobs and create a walkthrough of how to set it all up end to end.

– cs

1 Like