From 23d0021688877c1da49a3e4a288e9741785df6ec Mon Sep 17 00:00:00 2001 From: Jan Unterbrink Date: Mon, 23 Nov 2026 21:12:36 +0100 Subject: [PATCH] test(playback): compare two parsed URIs without identical expressions staticcheck (SA4000) flagged the equality check in TestValues because both sides were the same expression. Parse two separately written URIs instead; the test still checks that equal URIs compare equal with ==. Co-Authored-By: Claude Opus 5.5 --- internal/playback/playback_test.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/playback/playback_test.go b/internal/playback/playback_test.go index 22d41af..ae678a7 100644 --- a/internal/playback/playback_test.go +++ b/internal/playback/playback_test.go @@ -157,7 +157,9 @@ func TestValues(t *testing.T) { if Kinds()[0] != KindTrack() { t.Fatal("Kinds shared its slice") } - if must(ParseURI("spotify:track:1")) != must(ParseURI("spotify:track:1")) { + // Two separately parsed URIs with the same text are equal with ==. + a, b := must(ParseURI("spotify:track:1")), must(ParseURI(" spotify:track:1 ")) + if a != b { t.Fatal("equal URIs compare unequal") } for _, s := range []string{"", " ", "a b"} {