diff options
| author | Ophestra <cat@gensokyo.uk> | 2025-08-01 02:11:19 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2025-08-01 03:27:02 +0900 |
| commit | 987981df7313d0a121121be36f5c8cf86ffeacd1 (patch) | |
| tree | 90d342687c1da0d8d5a727faaa19786a43f3a962 /test/sandbox/configuration.nix | |
| parent | f14e7255be2cf766a63f08e53f6e1cb48e4d17dc (diff) | |
test/sandbox: check pd behaviour
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'test/sandbox/configuration.nix')
| -rw-r--r-- | test/sandbox/configuration.nix | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/test/sandbox/configuration.nix b/test/sandbox/configuration.nix index cfc1364e..77af45a4 100644 --- a/test/sandbox/configuration.nix +++ b/test/sandbox/configuration.nix @@ -6,6 +6,7 @@ }: let testProgram = pkgs.callPackage ./tool/package.nix { inherit (config.environment.hakurei.package) version; }; + testCases = import ./case pkgs.system lib testProgram; in { users.users = { @@ -26,6 +27,13 @@ in systemPackages = [ # For checking seccomp outcome: testProgram + + # For checking pd outcome: + (pkgs.writeShellScriptBin "check-sandbox-pd" '' + hakurei -v run hakurei-test \ + -t ${toString (builtins.toFile "hakurei-pd-want.json" (builtins.toJSON testCases.pd.want))} \ + -s ${testCases.pd.expectedFilter.${pkgs.system}} "$@" + '') ]; variables = { @@ -75,6 +83,6 @@ in } ]; - apps = import ./case pkgs.system lib testProgram; + inherit (testCases) apps; }; } |
