I have created new NTVS project and added new Mocha JS unit test from template:
So it doesn't work out of the box. How it is supposed to be run?
var assert = require('assert');
describe('Test Suite 1', function() {
it('Test 1', function() {
assert.ok(true, "This shouldn't fail");
})
it('Test 2', function() {
assert.ok(1 === 1, "This shouldn't fail");
assert.ok(false, "This should fail");
})
})
Run it from VS2013. Jasmine test runner was launched in a browser with obvious error: "Uncaught ReferenceError: require is not defined". Indeed browser knows nothing about require().So it doesn't work out of the box. How it is supposed to be run?