diff --git a/release.nix b/release.nix index eb1afa26..8de538ce 100644 --- a/release.nix +++ b/release.nix @@ -89,10 +89,12 @@ let examples.simple = genExample ./modules/examples/simple.nix; tests.system-packages = makeTest ./tests/system-packages.nix; + tests.system-path-bash = makeTest ./tests/system-path-bash.nix; + tests.system-path-fish = makeTest ./tests/system-path-fish.nix; + tests.system-path-zsh = makeTest ./tests/system-path-zsh.nix; } // (mapTestOn (packagePlatforms packageSet)); in - jobs diff --git a/tests/system-path-bash.nix b/tests/system-path-bash.nix new file mode 100644 index 00000000..b70fdc9e --- /dev/null +++ b/tests/system-path-bash.nix @@ -0,0 +1,12 @@ +{ config, pkgs, ... }: + +{ + environment.systemPath = [ pkgs.hello ]; + + programs.bash.enable = true; + + test = '' + echo checking systemPath in /etc/bashrc >&2 + grep 'export PATH=${pkgs.hello}/bin' ${config.out}/etc/bashrc + ''; +} diff --git a/tests/system-path-fish.nix b/tests/system-path-fish.nix new file mode 100644 index 00000000..0cd878e8 --- /dev/null +++ b/tests/system-path-fish.nix @@ -0,0 +1,12 @@ +{ config, pkgs, ... }: + +{ + environment.systemPath = [ pkgs.hello ]; + + programs.fish.enable = true; + + test = '' + echo checking systemPath in /etc/fish/config.fish >&2 + grep 'set PATH ${pkgs.hello}/bin' ${config.out}/etc/fish/config.fish + ''; +} diff --git a/tests/system-path-zsh.nix b/tests/system-path-zsh.nix new file mode 100644 index 00000000..222cbe94 --- /dev/null +++ b/tests/system-path-zsh.nix @@ -0,0 +1,12 @@ +{ config, pkgs, ... }: + +{ + environment.systemPath = [ pkgs.hello ]; + + programs.zsh.enable = true; + + test = '' + echo checking systemPath in /etc/zshrc >&2 + grep 'export PATH=${pkgs.hello}/bin' ${config.out}/etc/zshrc + ''; +}