Advertisement
Guest User

testMochaChai

a guest
Jul 28th, 2014
227
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. (function () {
  2.     require.config({
  3.         paths: {
  4.             "mocha": "bower_components/mocha/mocha",
  5.             "chai": "bower_components/chai/chai",
  6.             "mochaChaiInit": "scripts/mochaChaiInit",
  7.             "methods": "scripts/methods"
  8.         }
  9.     });
  10.  
  11.     require([ 'methods', 'mochaChaiInit', 'mocha' ], function (methods) {
  12.         describe('#sum', function () {
  13.             it('test method description', function () {
  14.                 var actual = methods.sum(1, 1);
  15.                 var expected = 2;
  16.  
  17.                 expect(actual).to.equal(expected);
  18.             });
  19.         });
  20.  
  21.         mocha.run();
  22.     });
  23. }());
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement