nushell: Add pluggin support tests
This commit is contained in:
parent
28e62eb5eb
commit
c580fa5960
|
@ -1 +1,4 @@
|
|||
{ nushell-example-settings = ./example-settings.nix; }
|
||||
{
|
||||
nushell-example-settings = ./example-settings.nix;
|
||||
nushell-plugins = ./plugins.nix;
|
||||
}
|
||||
|
|
22
tests/modules/programs/nushell/plugins.nix
Normal file
22
tests/modules/programs/nushell/plugins.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ pkgs, config, ... }:
|
||||
|
||||
{
|
||||
programs.nushell = {
|
||||
enable = true;
|
||||
plugins =
|
||||
builtins.attrValues { inherit (pkgs.nushellPlugins) formats gstat; };
|
||||
};
|
||||
|
||||
test.stubs."nushellPlugins.formats" = { };
|
||||
|
||||
nmt.script = let
|
||||
configDir = if pkgs.stdenv.isDarwin && !config.xdg.enable then
|
||||
"home-files/Library/Application Support/nushell"
|
||||
else
|
||||
"home-files/.config/nushell";
|
||||
pluginFile = "${configDir}/plugin.msgpackz";
|
||||
|
||||
in ''
|
||||
assertFileExists "${pluginFile}"
|
||||
'';
|
||||
}
|
Loading…
Reference in a new issue