Return matching_records list from top_albums_attach_metadata

Apply the same release-group JSON aggregation pattern to top albums
queries. Add JSON parsing in get_top_albums/1 and
get_top_albums_by_days/2.
This commit is contained in:
Claudio Ortolina
2026-04-14 16:05:51 +01:00
parent cfd267627c
commit 2c6e6e7ca2
2 changed files with 42 additions and 14 deletions
@@ -417,7 +417,6 @@ defmodule MusicLibrary.ListeningStatsTest do
end
end
@tag :skip
test "get_top_albums returns one entry per album", %{expected_record_id: expected_record_id} do
results = ListeningStats.get_top_albums(limit: 10)