depot/packages/catalog/checks.nix

22 lines
568 B
Nix
Raw Normal View History

2024-07-06 00:59:18 +03:00
{ lib, ... }:
{
perSystem = { config, ... }: {
catalog.depot = {
checks = lib.mapAttrs (name: check: {
description = "NixOS Test: ${name}";
actions = {
build = {
description = "Build this check.";
command = "nix build -L --no-link '${builtins.unsafeDiscardStringContext check.drvPath}^*'";
};
runInteractive = {
description = "Run interactive driver.";
command = lib.getExe check.driverInteractive;
};
};
}) config.checks;
};
};
}