2015-02-27 00:25:57 +00:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
var assert = require("assert");
|
2015-02-27 02:31:44 +00:00
|
|
|
var assets = require("../lib/node-ff-assets");
|
2015-02-27 00:25:57 +00:00
|
|
|
|
2015-02-27 02:31:44 +00:00
|
|
|
describe('lib/node-ff-assets.js', function() {
|
|
|
|
describe('check exports', function() {
|
2015-02-27 00:25:57 +00:00
|
|
|
it('asserts.factory should not be undefined', function() {
|
2015-02-27 02:31:44 +00:00
|
|
|
assert.equal(false, assets.factory === undefined);
|
2015-02-27 00:25:57 +00:00
|
|
|
});
|
|
|
|
it('asserts.AssetAssembler should not be undefined', function() {
|
2015-02-27 02:31:44 +00:00
|
|
|
assert.equal(false, assets.AssetAssembler === undefined);
|
2015-02-27 00:25:57 +00:00
|
|
|
});
|
|
|
|
it('asserts.checkAssemblerConfig should not be undefined', function() {
|
2015-02-27 02:31:44 +00:00
|
|
|
assert.equal(false, assets.checkAssemblerConfig === undefined);
|
2015-02-27 00:25:57 +00:00
|
|
|
});
|
|
|
|
it('asserts.AssetsBuilder should not be undefined', function() {
|
2015-02-27 02:31:44 +00:00
|
|
|
assert.equal(false, assets.AssetsBuilder === undefined);
|
2015-02-27 00:25:57 +00:00
|
|
|
});
|
|
|
|
it('asserts.checkBuilderConfig should not be undefined', function() {
|
2015-02-27 02:31:44 +00:00
|
|
|
assert.equal(false, assets.checkBuilderConfig === undefined);
|
|
|
|
});
|
|
|
|
it('asserts.build should not be undefined', function() {
|
|
|
|
assert.equal(false, assets.build === undefined);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
describe('asserts.build', function() {
|
|
|
|
it('check build missing config error', function() {
|
|
|
|
var err = null;
|
|
|
|
try {
|
|
|
|
assets.build();
|
|
|
|
} catch (error) {
|
|
|
|
err = error;
|
|
|
|
}
|
|
|
|
assert.equal(false, err === undefined);
|
2015-02-27 00:25:57 +00:00
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|