generateAlbumBanner.js 785 B

1234567891011121314151617181920212223242526272829303132333435
  1. import t from 'tap';
  2. import {testContentFunctions} from '#test-lib';
  3. testContentFunctions(t, 'generateAlbumBanner (snapshot)', async (t, evaluate) => {
  4. await evaluate.load();
  5. evaluate.snapshot('basic behavior', {
  6. name: 'generateAlbumBanner',
  7. args: [{
  8. directory: 'cool-album',
  9. hasBannerArt: true,
  10. bannerDimensions: [800, 200],
  11. bannerFileExtension: 'png',
  12. }],
  13. });
  14. evaluate.snapshot('no dimensions', {
  15. name: 'generateAlbumBanner',
  16. args: [{
  17. directory: 'cool-album',
  18. hasBannerArt: true,
  19. bannerDimensions: null,
  20. bannerFileExtension: 'png',
  21. }],
  22. });
  23. evaluate.snapshot('no banner', {
  24. name: 'generateAlbumBanner',
  25. args: [{
  26. directory: 'cool-album',
  27. hasBannerArt: false,
  28. }],
  29. });
  30. });