aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/pipewire/client_test.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2025-11-26 16:05:46 +0900
committerOphestra <cat@gensokyo.uk>2025-11-26 16:05:46 +0900
commitfd4d379b6777168c3251c85d153dbdf6b82f2b35 (patch)
tree348f190575762ef6655ce9f2a1119c16d2c5eebd /internal/pipewire/client_test.go
parent77f5b89a4180600179d4f0d1683b063b43372811 (diff)
internal/pipewire: implement Client::Info
Everything is already supported, as usual. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/pipewire/client_test.go')
-rw-r--r--internal/pipewire/client_test.go21
1 files changed, 21 insertions, 0 deletions
diff --git a/internal/pipewire/client_test.go b/internal/pipewire/client_test.go
index 378112be..c9d790ce 100644
--- a/internal/pipewire/client_test.go
+++ b/internal/pipewire/client_test.go
@@ -6,6 +6,27 @@ import (
"hakurei.app/internal/pipewire"
)
+func TestClientInfo(t *testing.T) {
+ t.Parallel()
+
+ encodingTestCases[pipewire.ClientInfo, *pipewire.ClientInfo]{
+ {"sample", []byte(recvmsg00Message02POD), pipewire.ClientInfo{
+ ID: 34,
+ ChangeMask: pipewire.PW_CLIENT_CHANGE_MASK_PROPS,
+ Props: &pipewire.SPADict{NItems: 9, Items: []pipewire.SPADictItem{
+ {Key: "pipewire.protocol", Value: "protocol-native"},
+ {Key: "core.name", Value: "pipewire-0"},
+ {Key: "pipewire.sec.socket", Value: "pipewire-0-manager"},
+ {Key: "pipewire.sec.pid", Value: "1443"},
+ {Key: "pipewire.sec.uid", Value: "1000"},
+ {Key: "pipewire.sec.gid", Value: "100"},
+ {Key: "module.id", Value: "2"},
+ {Key: "object.id", Value: "34"},
+ {Key: "object.serial", Value: "34"},
+ }}}, nil},
+ }.run(t)
+}
+
func TestClientUpdateProperties(t *testing.T) {
t.Parallel()