add features

This commit is contained in:
2026-07-29 04:35:25 -05:00
parent 23c6113b33
commit cab5a987b0
29 changed files with 1179 additions and 89 deletions
+22
View File
@@ -0,0 +1,22 @@
package backend
import (
"testing"
"github.com/dweymouth/supersonic/backend/mediaprovider"
)
func TestFetchLyricsAsyncWithNilTrack(t *testing.T) {
lm := &LyricsManager{}
called := false
lm.FetchLyricsAsync(nil, func(id string, lyrics *mediaprovider.Lyrics) {
called = true
if id != "" || lyrics != nil {
t.Fatalf("got callback values (%q, %v), want empty ID and nil lyrics", id, lyrics)
}
})
if !called {
t.Fatal("callback was not called")
}
}