25 行
646 B
JavaScript
25 行
646 B
JavaScript
const radiomanifest = require('../radiomanifest.js')
|
|
const chai = require('chai')
|
|
chai.use(require('chai-as-promised'))
|
|
|
|
const expect = chai.expect
|
|
|
|
describe('radiomanifest.js', () => {
|
|
describe('Get a radiomanifest', () => {
|
|
it('should return a Promise', () => {
|
|
const p = radiomanifest.get('http://example.com/')
|
|
expect(p instanceof Promise).to.be.eql(true)
|
|
})
|
|
|
|
it('should reject on invalid URL', () => {
|
|
const p = radiomanifest.get('http://example.com/')
|
|
expect(p).to.eventually.be.rejected
|
|
})
|
|
})
|
|
|
|
describe('streaming', () => {
|
|
it('shoud return a valid streaming URL', () => {
|
|
|
|
})
|
|
})
|
|
})
|