aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2024-12-21 17:58:14 +0900
committerOphestra <cat@gensokyo.uk>2024-12-21 17:58:14 +0900
commitf8c3d533274f7ceea443bc4650173a1232808d1a (patch)
tree80f36dfe1d12337261cd6fb2dc9142a25cdfbbcc
parent74fe74e6b510291ad480a23c3ec37db0b14c7815 (diff)
nix: test pulseaudio pass through
Signed-off-by: Ophestra <cat@gensokyo.uk>
-rw-r--r--test.nix19
1 files changed, 19 insertions, 0 deletions
diff --git a/test.nix b/test.nix
index ca0b1f49..03266fad 100644
--- a/test.nix
+++ b/test.nix
@@ -77,6 +77,16 @@ nixosTest {
programs.sway.enable = true;
+ # For PulseAudio tests:
+ security.rtkit.enable = true;
+ services.pipewire = {
+ enable = true;
+ alsa.enable = true;
+ alsa.support32Bit = true;
+ pulse.enable = true;
+ jack.enable = true;
+ };
+
virtualisation.qemu.options = [
# Need to switch to a different GPU driver than the default one (-vga std) so that Sway can launch:
"-vga none -device virtio-gpu-pci"
@@ -197,6 +207,15 @@ nixosTest {
machine.send_chars("exit\n")
machine.wait_until_fails("pgrep foot")
+ # Test PulseAudio (fortify does not support PipeWire yet):
+ swaymsg("exec fortify run --wayland --pulse foot")
+ wait_for_window("u0_a0@machine")
+ machine.send_chars("pactl info && touch /tmp/success-pulse\n")
+ machine.wait_for_file("/tmp/fortify.1000/tmpdir/0/success-pulse")
+ collect_state_ui("pulse_wayland")
+ machine.send_chars("exit\n")
+ machine.wait_until_fails("pgrep foot")
+
# Test XWayland (foot does not support X):
swaymsg("exec fortify run -X alacritty")
wait_for_window("u0_a0@machine")