Track fixture files as external resources

This commit is contained in:
Claudio Ortolina
2026-04-17 14:02:45 +01:00
parent 079f2a5f0f
commit fd6eab82c0
7 changed files with 33 additions and 0 deletions
+1
View File
@@ -2,6 +2,7 @@ defmodule LastFm.Fixtures.Artist do
@fixtures_folder Path.join([File.cwd!(), "test/support/fixtures/last_fm"])
# Cache fixtures at compile time to avoid repeated file I/O
@external_resource Path.join([@fixtures_folder, "artist.getinfo.json"])
@get_info Path.join([@fixtures_folder, "artist.getinfo.json"])
|> File.read!()
|> JSON.decode!()