mirror of
https://github.com/nix-community/home-manager
synced 2025-02-16 22:18:24 +00:00
Instead of having to manually stub packages that should not be downloaded we instead automatically stub all packages (except a small list of whitelisted ones). Tests can re-introduce the real package by using the `realPkgs` module argument.
25 lines
489 B
Nix
25 lines
489 B
Nix
{ pkgs, ... }:
|
|
|
|
{
|
|
services.mopidy = {
|
|
enable = true;
|
|
extensionPackages = [ pkgs.mopidy-local ];
|
|
};
|
|
|
|
test.stubs = {
|
|
mopidy = {
|
|
version = "0";
|
|
outPath = null;
|
|
buildScript = ''
|
|
mkdir -p $out/bin
|
|
touch $out/bin/mopidy
|
|
chmod +x $out/bin/mopidy
|
|
'';
|
|
};
|
|
};
|
|
|
|
nmt.script = ''
|
|
assertFileExists home-files/.config/systemd/user/mopidy.service
|
|
assertFileExists home-files/.config/systemd/user/mopidy-scan.service
|
|
'';
|
|
}
|