diff options
-rw-r--r-- | tap-snapshots/test/snapshot/generateTrackCoverArtwork.js.test.cjs | 16 | ||||
-rw-r--r-- | test/snapshot/generateAlbumCoverArtwork.js | 8 | ||||
-rw-r--r-- | test/snapshot/generateTrackCoverArtwork.js | 15 |
3 files changed, 25 insertions, 14 deletions
diff --git a/tap-snapshots/test/snapshot/generateTrackCoverArtwork.js.test.cjs b/tap-snapshots/test/snapshot/generateTrackCoverArtwork.js.test.cjs index 29399c70..c87d88c6 100644 --- a/tap-snapshots/test/snapshot/generateTrackCoverArtwork.js.test.cjs +++ b/tap-snapshots/test/snapshot/generateTrackCoverArtwork.js.test.cjs @@ -5,7 +5,7 @@ * Make sure to inspect the output below. Do not ignore changes! */ 'use strict' -exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: primary - no unique art 1`] = ` +exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: primary-tags - no unique art 1`] = ` [mocked: image args: [ [ @@ -15,19 +15,19 @@ exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverAr { name: 'creepy crawlies', isContentWarning: true } ] ] - slots: { path: [ 'media.albumCover', 'bee-forus-seatbelt-safebee', 'png' ], color: '#abcdef', thumb: 'medium', reveal: true, link: true, dimensions: [ 400, 300 ] }] -<ul class="image-details"> + slots: { path: [ 'media.albumCover', 'bee-forus-seatbelt-safebee', 'png' ], alt: 'track cover', color: '#abcdef', thumb: 'medium', reveal: true, link: true, dimensions: [ 400, 300 ] }] +<ul class="image-details art-tag-details"> <li><a href="tag/damara/">Damara</a></li> <li><a href="tag/cronus/">Cronus</a></li> <li><a href="tag/bees/">Bees</a></li> </ul> ` -exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: primary - unique art 1`] = ` +exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: primary-tags - unique art 1`] = ` [mocked: image args: [ [ { name: 'Bees', directory: 'bees', isContentWarning: false } ] ] - slots: { path: [ 'media.trackCover', 'bee-forus-seatbelt-safebee', 'beesmp3', 'jpg' ], color: '#f28514', thumb: 'medium', reveal: true, link: true, square: true }] -<ul class="image-details"><li><a href="tag/bees/">Bees</a></li></ul> + slots: { path: [ 'media.trackCover', 'bee-forus-seatbelt-safebee', 'beesmp3', 'jpg' ], alt: 'track cover', color: '#f28514', thumb: 'medium', reveal: true, link: true, square: true }] +<ul class="image-details art-tag-details"><li><a href="tag/bees/">Bees</a></li></ul> ` exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: thumbnail - no unique art 1`] = ` @@ -40,11 +40,11 @@ exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverAr { name: 'creepy crawlies', isContentWarning: true } ] ] - slots: { path: [ 'media.albumCover', 'bee-forus-seatbelt-safebee', 'png' ], color: '#abcdef', thumb: 'small', reveal: false, link: false, dimensions: [ 400, 300 ] }] + slots: { path: [ 'media.albumCover', 'bee-forus-seatbelt-safebee', 'png' ], alt: 'track cover', color: '#abcdef', thumb: 'small', reveal: false, link: false, dimensions: [ 400, 300 ] }] ` exports[`test/snapshot/generateTrackCoverArtwork.js > TAP > generateTrackCoverArtwork (snapshot) > display: thumbnail - unique art 1`] = ` [mocked: image args: [ [ { name: 'Bees', directory: 'bees', isContentWarning: false } ] ] - slots: { path: [ 'media.trackCover', 'bee-forus-seatbelt-safebee', 'beesmp3', 'jpg' ], color: '#f28514', thumb: 'small', reveal: false, link: false, square: true }] + slots: { path: [ 'media.trackCover', 'bee-forus-seatbelt-safebee', 'beesmp3', 'jpg' ], alt: 'track cover', color: '#f28514', thumb: 'small', reveal: false, link: false, square: true }] ` diff --git a/test/snapshot/generateAlbumCoverArtwork.js b/test/snapshot/generateAlbumCoverArtwork.js index 939c6e19..52b4f9bb 100644 --- a/test/snapshot/generateAlbumCoverArtwork.js +++ b/test/snapshot/generateAlbumCoverArtwork.js @@ -21,12 +21,16 @@ testContentFunctions(t, 'generateAlbumCoverArtwork (snapshot)', async (t, evalua {name: 'Bees', directory: 'bees', isContentWarning: false}, {name: 'creepy crawlies', isContentWarning: true}, ], + coverArtistContribs: [ + {artist: {name: 'Circlejourney', directory: 'circlejourney'}}, + {artist: {name: 'magnoliajades', directory: 'magnoliajades'}}, + ], }; - evaluate.snapshot('display: primary', { + evaluate.snapshot('display: primary-tags', { name: 'generateAlbumCoverArtwork', args: [album], - slots: {mode: 'primary'}, + slots: {mode: 'primary-tags'}, }); evaluate.snapshot('display: thumbnail', { diff --git a/test/snapshot/generateTrackCoverArtwork.js b/test/snapshot/generateTrackCoverArtwork.js index 4d952119..8f6ce772 100644 --- a/test/snapshot/generateTrackCoverArtwork.js +++ b/test/snapshot/generateTrackCoverArtwork.js @@ -18,6 +18,10 @@ testContentFunctions(t, 'generateTrackCoverArtwork (snapshot)', async (t, evalua {name: 'Bees', directory: 'bees', isContentWarning: false}, {name: 'creepy crawlies', isContentWarning: true}, ], + coverArtistContribs: [ + {artist: {name: 'Circlejourney', directory: 'circlejourney'}}, + {artist: {name: 'magnoliajades', directory: 'magnoliajades'}}, + ], }; const track1 = { @@ -27,6 +31,9 @@ testContentFunctions(t, 'generateTrackCoverArtwork (snapshot)', async (t, evalua coverArtDimensions: null, color: '#f28514', artTags: [{name: 'Bees', directory: 'bees', isContentWarning: false}], + coverArtistContribs: [ + {artist: {name: 'Circlejourney', directory: 'circlejourney'}}, + ], album, }; @@ -37,10 +44,10 @@ testContentFunctions(t, 'generateTrackCoverArtwork (snapshot)', async (t, evalua album, }; - evaluate.snapshot('display: primary - unique art', { + evaluate.snapshot('display: primary-tags - unique art', { name: 'generateTrackCoverArtwork', args: [track1], - slots: {mode: 'primary'}, + slots: {mode: 'primary-tags'}, }); evaluate.snapshot('display: thumbnail - unique art', { @@ -49,10 +56,10 @@ testContentFunctions(t, 'generateTrackCoverArtwork (snapshot)', async (t, evalua slots: {mode: 'thumbnail'}, }); - evaluate.snapshot('display: primary - no unique art', { + evaluate.snapshot('display: primary-tags - no unique art', { name: 'generateTrackCoverArtwork', args: [track2], - slots: {mode: 'primary'}, + slots: {mode: 'primary-tags'}, }); evaluate.snapshot('display: thumbnail - no unique art', { |