How to use the chimp.chai function in chimp

To help you get started, we’ve selected a few chimp examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github TheBrainFamily / chimpy / dist / lib / chimp-helper.js View on Github external
loadAssertionLibrary: function loadAssertionLibrary() {
    if (booleanHelper.isTruthy(process.env['chimp.chai'])) {
      log.debug('[chimp][helper] Using the chai-expect assertion library');
      chai.use(chaiAsPromised);
      chai.should();
      // give users access to the chai instance
      global.chai = chai;
      global.expect = chai.expect;
      global.assert = chai.assert;
    } else {
      log.debug('[chimp][helper] Using the jasmine-expect assertion library');
      global.expect = require('xolvio-jasmine-expect').expect;
    }
  },
github TheBrainFamily / chimpy / src / lib / chimp-helper.js View on Github external
loadAssertionLibrary: function () {
    if (booleanHelper.isTruthy(process.env['chimp.chai'])) {
      log.debug('[chimp][helper] Using the chai-expect assertion library');
      chai.use(chaiAsPromised);
      chai.should();
      // give users access to the chai instance
      global.chai = chai;
      global.expect = chai.expect;
      global.assert = chai.assert;
    } else {
      log.debug('[chimp][helper] Using the jasmine-expect assertion library');
      global.expect = require('xolvio-jasmine-expect').expect;
    }
  },
github TheBrainFamily / chimpy / dist / lib / mocha / mocha-helper.js View on Github external
before(function () {
  process.env['chimp.chai'] = true;
  chimpHelper.loadAssertionLibrary();
  chimpHelper.init();
  chimpHelper.setupBrowserAndDDP();
});
github TheBrainFamily / chimpy / src / lib / mocha / mocha-helper.js View on Github external
before(function () {
  process.env['chimp.chai'] = true;
  chimpHelper.loadAssertionLibrary();
  chimpHelper.init();
  chimpHelper.setupBrowserAndDDP();
});