test: invented artists, albums and MusicBrainz ids in place of real ones
release / web (push) Failing after 1m16s
release / go (push) Successful in 1m48s
release / govulncheck (push) Successful in 20s
release / integration (push) Successful in 4m0s
release / android (push) Successful in 4m34s
release / Build signed APK (push) Successful in 5m9s
release / Attach APK to the Release (tag releases only) (push) Skipped
release / Build + push container image (push) Skipped
release / Verify release artifacts (tag releases only) (push) Skipped
release / web (push) Failing after 1m16s
release / go (push) Successful in 1m48s
release / govulncheck (push) Successful in 20s
release / integration (push) Successful in 4m0s
release / android (push) Successful in 4m34s
release / Build signed APK (push) Successful in 5m9s
release / Attach APK to the Release (tag releases only) (push) Skipped
release / Build + push container image (push) Skipped
release / Verify release artifacts (tag releases only) (push) Skipped
Test data and example comments named real artists, records and songs, and carried real MusicBrainz ids. One mapping swaps them for invented ones throughout (Fields of Ontario, Plastic Apes, Marlo Davies, ...), keeping what each case tests: sort order, index letter, escaping, title keys, artist-prefix stripping. A test username is no longer the operator's name. The cover-art and Last.fm connection checks still query real releases; they reach live services and need something that exists there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -15,11 +15,11 @@ func TestHandleExportMissingTracks_Integration(t *testing.T) {
|
||||
h, pool := testHandlers(t)
|
||||
truncateLibrary(t, pool)
|
||||
admin := seedUser(t, pool, "export-admin", "pw", true)
|
||||
artist := seedArtist(t, pool, "Boards of Canada")
|
||||
album := seedAlbum(t, pool, artist.ID, "Geogaddi", 2002)
|
||||
gone := seedTrack(t, pool, album.ID, artist.ID, "Music Is Math", 0, 300_000)
|
||||
removed := seedTrack(t, pool, album.ID, artist.ID, "Dawn Chorus", 2, 240_000)
|
||||
seedTrack(t, pool, album.ID, artist.ID, "Julie and Candy", 3, 200_000)
|
||||
artist := seedArtist(t, pool, "Fields of Ontario")
|
||||
album := seedAlbum(t, pool, artist.ID, "Geomantic", 2002)
|
||||
gone := seedTrack(t, pool, album.ID, artist.ID, "Music Is Maps", 0, 300_000)
|
||||
removed := seedTrack(t, pool, album.ID, artist.ID, "Dusk Chorus", 2, 240_000)
|
||||
seedTrack(t, pool, album.ID, artist.ID, "Julia and Cane", 3, 200_000)
|
||||
ctx := context.Background()
|
||||
if _, err := pool.Exec(ctx, `UPDATE tracks SET missing_since = now() WHERE id = $1`, gone.ID); err != nil {
|
||||
t.Fatal(err)
|
||||
@@ -46,10 +46,10 @@ func TestHandleExportMissingTracks_Integration(t *testing.T) {
|
||||
for _, r := range rows[1:] {
|
||||
byTitle[r[4]] = r
|
||||
}
|
||||
if r := byTitle["Music Is Math"]; r == nil || r[3] != "" || r[5] != "" || r[7] != "missing" {
|
||||
if r := byTitle["Music Is Maps"]; r == nil || r[3] != "" || r[5] != "" || r[7] != "missing" {
|
||||
t.Errorf("untagged missing row = %v, want no track number, no mbid, why missing", r)
|
||||
}
|
||||
if r := byTitle["Dawn Chorus"]; r == nil || r[3] != "2" || r[5] != "rec-dawn" || r[7] != "report" {
|
||||
if r := byTitle["Dusk Chorus"]; r == nil || r[3] != "2" || r[5] != "rec-dawn" || r[7] != "report" {
|
||||
t.Errorf("removed row = %v, want track 2, its mbid, why report", r)
|
||||
}
|
||||
}
|
||||
@@ -60,8 +60,8 @@ func TestHandleForgetMissingTracks_Integration(t *testing.T) {
|
||||
h, pool := testHandlers(t)
|
||||
truncateLibrary(t, pool)
|
||||
admin := seedUser(t, pool, "forget-admin", "pw", true)
|
||||
artist := seedArtist(t, pool, "Autechre")
|
||||
album := seedAlbum(t, pool, artist.ID, "Amber", 1994)
|
||||
artist := seedArtist(t, pool, "Autoglyph")
|
||||
album := seedAlbum(t, pool, artist.ID, "Ochre", 1994)
|
||||
waiting := seedTrack(t, pool, album.ID, artist.ID, "Foil", 1, 300_000)
|
||||
present := seedTrack(t, pool, album.ID, artist.ID, "Montreal", 2, 300_000)
|
||||
ctx := context.Background()
|
||||
|
||||
Reference in New Issue
Block a user