Files
clan-core/clanServices/zerotier/tests/vm/default.nix
a-kenji 96325c0c29 clanServices/zerotier: Add eval tests
Add eval tests to the zerotier clanService module.

The vm module is a stub that acts as an api for the `generate-test-vars`
script, as that currently only works with a vm, not with an eval test.

This checks, if all the peers pick up their respective configuration
correctly. Without running the service itself.
2025-06-13 14:58:27 +02:00

44 lines
736 B
Nix

{
pkgs,
nixosLib,
clan-core,
module,
...
}:
nixosLib.runTest (
{ ... }:
{
imports = [
clan-core.modules.nixosVmTest.clanTest
];
hostPkgs = pkgs;
name = "zerotier";
clan = {
directory = ./.;
modules."zerotier" = module;
inventory = {
machines.jon = { };
machines.sara = { };
machines.bam = { };
instances = {
"zerotier" = {
module.name = "zerotier";
roles.peer.tags.all = { };
roles.controller.machines.bam = { };
};
};
};
};
# This is not an actual vm test, this is a workaround to
# generate the needed vars for the eval test.
testScript = '''';
}
)