Namespace Last.Fm fixtures

This commit is contained in:
Claudio Ortolina
2025-02-17 15:51:47 +00:00
parent 5a391eb549
commit d27f3ccf72
8 changed files with 9 additions and 9 deletions
+13
View File
@@ -0,0 +1,13 @@
defmodule LastFm.Fixtures.Artist do
@fixtures_folder Path.join([File.cwd!(), "test/support/fixtures/last_fm"])
alias LastFm.Artist
def get_info do
Path.join([@fixtures_folder, "artist.getinfo.json"])
|> File.read!()
|> JSON.decode!()
|> Map.get("artist")
|> Artist.from_api_response()
end
end