evcc: 0.131.4 -> 0.131.5
[NixPkgs.git] / pkgs / by-name / in / installShellFiles / tests / install-completion-fifo.nix
blob2c777f0fb68a191913bed7e1b5f0cefc5ddbeba5
2   lib,
3   installShellFiles,
4   runCommandLocal,
5 }:
7 runCommandLocal "install-shell-files--install-completion-fifo"
8   {
9     nativeBuildInputs = [ installShellFiles ];
10     meta.platforms = lib.platforms.all;
11   }
12   ''
13     installShellCompletion \
14       --bash --name foo.bash <(echo foo) \
15       --zsh --name _foo <(echo bar) \
16       --fish --name foo.fish <(echo baz)
18     [[ $(<$out/share/bash-completion/completions/foo.bash) == foo ]] || { echo "foo.bash comparison failed"; exit 1; }
19     [[ $(<$out/share/zsh/site-functions/_foo) == bar ]] || { echo "_foo comparison failed"; exit 1; }
20     [[ $(<$out/share/fish/vendor_completions.d/foo.fish) == baz ]] || { echo "foo.fish comparison failed"; exit 1; }
21   ''