diff options
author | github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | 2021-11-09 00:01:30 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-09 00:01:30 +0000 |
commit | 707b006bf7ea81dae47511d7008a4c93ff62875a (patch) | |
tree | 945c06b22a98ce9d3d1b3bb9d538442bd8d930b3 /nixos/tests | |
parent | f14d7cb2f666e85da4e69c9b8b1e8c24860cf91c (diff) | |
parent | db6044d5debaff0749420c3553d1b89fc6c5c5f8 (diff) |
Merge master into staging-next
Diffstat (limited to 'nixos/tests')
-rw-r--r-- | nixos/tests/doas.nix | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/nixos/tests/doas.nix b/nixos/tests/doas.nix index 5e9ce4b2c799..7f038b2bee29 100644 --- a/nixos/tests/doas.nix +++ b/nixos/tests/doas.nix @@ -85,6 +85,14 @@ import ./make-test-python.nix ( # ../../pkgs/tools/security/doas/0001-add-NixOS-specific-dirs-to-safe-PATH.patch with subtest("recursive calls to doas from subprocesses should succeed"): machine.succeed('doas -u test0 sh -c "doas -u test0 true"') + + with subtest("test0 should inherit TERMINFO_DIRS from the user environment"): + dirs = machine.succeed( + "su - test0 -c 'doas -u root $SHELL -c \"echo \$TERMINFO_DIRS\"'" + ) + + if not "test0" in dirs: + raise Exception(f"user profile TERMINFO_DIRS is not preserved: {dirs}") ''; } ) |