Skip to content

Instantly share code, notes, and snippets.

@poliveira89
Created July 3, 2015 09:48
Show Gist options
  • Save poliveira89/c84380c3f0cf4467a460 to your computer and use it in GitHub Desktop.
Save poliveira89/c84380c3f0cf4467a460 to your computer and use it in GitHub Desktop.
hapijs testing with lab
$ lab
.
1 tests complete
Test duration: 28 ms
No global variable leaks detected
var Code = require('code'); // assertion library
var Lab = require('lab');
var lab = exports.lab = Lab.script();
lab.experiment('test base', function() {
lab.test('something', function(done) {
var hello = 'hello';
Code.expect(hello).to.equal('hello');
done();
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment