html2canvas/tests/node/package.js

16 lines
426 B
JavaScript
Raw Normal View History

2017-12-03 12:07:10 +03:00
const assert = require('assert');
const html2canvas = require('../../');
2015-01-20 00:33:29 +03:00
2017-12-03 12:07:10 +03:00
describe('Package', () => {
it('should have html2canvas defined', () => {
2017-08-08 19:50:31 +03:00
assert.equal(typeof html2canvas, 'function');
2015-01-20 00:33:29 +03:00
});
2015-08-30 02:27:38 +03:00
2017-12-03 12:07:10 +03:00
it('should have html2canvas defined', done => {
2017-12-03 12:30:52 +03:00
html2canvas('').catch(err => {
2017-12-03 12:07:10 +03:00
assert.equal(err, 'Provided element is not within a Document');
2015-08-30 02:27:38 +03:00
done();
2017-12-03 12:30:52 +03:00
});
2015-08-30 02:27:38 +03:00
});
});