html2canvas/tests/node/package.js

25 lines
627 B
JavaScript
Raw Normal View History

2015-01-20 00:33:29 +03:00
var assert = require('assert');
2015-08-30 02:27:38 +03:00
var path = require('path');
2015-01-20 00:33:29 +03:00
var html2canvas = require('../../');
2017-08-08 19:50:31 +03:00
describe('Package', function() {
it('should have html2canvas defined', function() {
assert.equal(typeof html2canvas, 'function');
2015-01-20 00:33:29 +03:00
});
});
2015-08-30 02:27:38 +03:00
2017-08-08 19:50:31 +03:00
describe.only('requirejs', function() {
2015-08-30 02:27:38 +03:00
var requirejs = require('requirejs');
requirejs.config({
baseUrl: path.resolve(__dirname, '../../dist')
});
2017-08-08 19:50:31 +03:00
it('should have html2canvas defined', function(done) {
2015-08-30 02:27:38 +03:00
requirejs(['html2canvas'], function(h2c) {
2017-08-08 19:50:31 +03:00
assert.equal(typeof h2c, 'function');
2015-08-30 02:27:38 +03:00
done();
});
});
});