shallow.test.js 672 B

123456789101112131415161718192021222324
  1. var assert = require('chai').assert,
  2. lib = require('../lib/deap'),
  3. shallow = require('../shallow');
  4. describe('shallow', function() {
  5. it('should be defined correctly', function() {
  6. assert.isFunction(shallow);
  7. assert.isFunction(shallow.extend);
  8. assert.isFunction(shallow.update);
  9. assert.isFunction(shallow.merge);
  10. assert.isFunction(shallow.clone);
  11. });
  12. it('should have shallow functions', function() {
  13. assert.equal(shallow, lib.extendShallow);
  14. assert.equal(shallow.extend, lib.extendShallow);
  15. assert.equal(shallow.update, lib.updateShallow);
  16. assert.equal(shallow.merge, lib.mergeShallow);
  17. assert.equal(shallow.clone, lib.cloneShallow);
  18. });
  19. });