29-May-2025, 10:30 AM
This is probably one of the most difficult thing to do - unit testing.
So there are three environments involved:
Now the idea is I can expand on the build environments to introduce more builds (e.g. RHEL, or RaspOS, and so on). And the CI pipeline will run and ensure everything is going smoothly. While this is a lot of work, the solution will scale, and more importantly, the quality of Snakeoil is now hard checked (if tests fail the build will fail).
Here's the new stage (unit test), run at the first stage of the pipeline:
And here are the details of the tests:
It's a lot of effort just to get these 10 tests to work, but today it's finally working!
This is just the beginning of the unit tests framework - over time i intend to add more unit tests to automate a lot of things, example:
So there are three environments involved:
- My development environment (Ubuntu 24.04 LTS)
- Raspberry Pi build environment (Ubuntu 24.04 LTS)
- Intel/AMD build environment (Ubuntu 24.04 LTS)
Now the idea is I can expand on the build environments to introduce more builds (e.g. RHEL, or RaspOS, and so on). And the CI pipeline will run and ensure everything is going smoothly. While this is a lot of work, the solution will scale, and more importantly, the quality of Snakeoil is now hard checked (if tests fail the build will fail).
Here's the new stage (unit test), run at the first stage of the pipeline:
And here are the details of the tests:
It's a lot of effort just to get these 10 tests to work, but today it's finally working!
This is just the beginning of the unit tests framework - over time i intend to add more unit tests to automate a lot of things, example:
- Test install/uninstall of players to make sure they still work (Now this will require root access, so I might move to a docker CI environment)
- whatever I can think of down the road
Snakeoil Operating System - Music, your way!