vk-music-dl/test/lib.test.js

15 lines
508 B
JavaScript
Raw Normal View History

2020-09-27 10:41:03 +02:00
'use strict';
const assert = require('assert');
const {getSpotifyPlaylist} = require('../lib');
describe('getSpotifyPlaylist', function(){
it('acquire and parse playlist from Spotify', async function(){
const playlist = await getSpotifyPlaylist('https://open.spotify.com/playlist/27OFA3NDwoLWtmdMvowA3S');
assert.strictEqual(playlist.name, 'The Best Yoga & Cool-Down Songs');
assert.strictEqual(playlist.type, 'playlist');
assert.strictEqual(playlist.tracks.items.length, 10);
});
});