-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtests.js
More file actions
25 lines (21 loc) · 780 Bytes
/
tests.js
File metadata and controls
25 lines (21 loc) · 780 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
'use strict';
var assert = require('assert');
var musicMeta = require('./index');
// it('should return artist bio, tags and image', function () {
// musicMeta.getArtist('The Birthday Party', 'large')
// .then(function() {
// assert.strictEqual(url.indexOf('http'), 0);
// })
// })
it('should return album artwork and tracklisting', function () {
musicMeta.getAlbum('Junkyard', 'The Birthday Party', 'large')
.then(function(data) {
var artist = data.artist
var album = data.album
var albumArtwork = data.albumArtwork
var tracklist = data.trackList
assert.strictEqual(albumArtwork.indexOf('http'), 0);
assert.strictEqual(artist, 'The Birthday Party')
assert.strictEqual(tracklist[3].title, 'Dead Joe')
})
})