aboutsummaryrefslogtreecommitdiff
path: root/home-manager/tests/modules/services/fluidsynth/service.nix
diff options
context:
space:
mode:
Diffstat (limited to 'home-manager/tests/modules/services/fluidsynth/service.nix')
-rw-r--r--home-manager/tests/modules/services/fluidsynth/service.nix24
1 files changed, 24 insertions, 0 deletions
diff --git a/home-manager/tests/modules/services/fluidsynth/service.nix b/home-manager/tests/modules/services/fluidsynth/service.nix
new file mode 100644
index 00000000000..8d53e75c032
--- /dev/null
+++ b/home-manager/tests/modules/services/fluidsynth/service.nix
@@ -0,0 +1,24 @@
+{ config, pkgs, ... }: {
+ config = {
+ services.fluidsynth.enable = true;
+ services.fluidsynth.soundFont = "/path/to/soundFont";
+ services.fluidsynth.extraOptions = [ "--sample-rate 96000" ];
+
+ nixpkgs.overlays = [
+ (self: super: {
+ fluidsynth = pkgs.writeScriptBin "dummy-fluidsynth" "" // {
+ outPath = "@fluidsynth@";
+ };
+ })
+ ];
+
+ nmt.script = ''
+ serviceFile=home-files/.config/systemd/user/fluidsynth.service
+
+ assertFileExists $serviceFile
+
+ assertFileContains $serviceFile \
+ 'ExecStart=@fluidsynth@/bin/fluidsynth -a pulseaudio -si --sample-rate 96000 /path/to/soundFont'
+ '';
+ };
+}