mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-03-22 15:29:07 +01:00
tests: Add infrastructure-test
This commit is contained in:
parent
4a6a391eb0
commit
8f61e81e81
14 changed files with 212 additions and 0 deletions
28
flake-parts/tests.nix
Normal file
28
flake-parts/tests.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{ inputs, self, ... }:
|
||||
{
|
||||
perSystem =
|
||||
{ pkgs, lib, ... }:
|
||||
{
|
||||
checks =
|
||||
"${self}/tests"
|
||||
|> builtins.readDir
|
||||
|> lib.attrNames
|
||||
|> lib.map (name: {
|
||||
name = "${name}-test";
|
||||
value = pkgs.testers.runNixOSTest (
|
||||
{
|
||||
name = "${name}-test";
|
||||
}
|
||||
// import "${self}/tests/${name}" {
|
||||
inherit
|
||||
inputs
|
||||
self
|
||||
pkgs
|
||||
lib
|
||||
;
|
||||
}
|
||||
);
|
||||
})
|
||||
|> lib.listToAttrs;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue