Contract-test our interaction with NixOps4 #90

Closed
opened 2025-01-31 11:04:47 +01:00 by fricklerhandwerk · 2 comments

NixOps4 is still under heavy development, and we need to make sure that when we're interfacing with it, our code doesn't break when updating NixOps4. Having our own test guards against accidental backwards-incompatible changes on the NixOps4 side that will break our deployments at time of use. Instead we will get notified at time of dependency update by a failing test.

Thinking about it, we probably want to have our entire deployment tested against a simulated environment to exercise all the code paths currently in use...

NixOps4 is still under heavy development, and we need to make sure that when we're interfacing with it, our code doesn't break when updating NixOps4. Having our own test guards against accidental backwards-incompatible changes on the NixOps4 side that will break our deployments at time of use. Instead we will get notified at time of dependency update by a failing test. Thinking about it, we probably want to have our entire deployment tested against a simulated environment to exercise all the code paths currently in use...
Owner

You can use the nixops4-nixos VM test as a reference. (permalink)

Ideally we also make use of the fact that these tests are modules, so we can factor out common bits if that makes sense.
Probably the deployer node can be factored into a nixops4-nixos.modules.nixosTests.test-infra module or something. Maybe also other things. Options can be added to control testScript and whatnot, as needed.

You can use the [nixops4-nixos VM test](https://github.com/nixops4/nixops4-nixos/blob/main/test/default/nixosTest.nix) as a reference. ([permalink](https://github.com/nixops4/nixops4-nixos/blob/65fe4b132fe299e03ee387d67d3fee1eb4593f4f/test/default/nixosTest.nix)) Ideally we also make use of the fact that these tests are modules, so we can factor out common bits if that makes sense. Probably the `deployer` node can be factored into a `nixops4-nixos.modules.nixosTests.test-infra` module or something. Maybe also other things. Options can be added to control `testScript` and whatnot, as needed.
Owner

closing in favor of #276

closing in favor of #276
kiara closed this issue 2025-04-30 09:13:55 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: fediversity/fediversity#90
No description provided.