-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
306 additions
and
147 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,27 @@ | ||
'use strict'; | ||
|
||
var test = require('tap').test; | ||
var lab = exports.lab = require('lab').script(); | ||
var describe = lab.describe; | ||
var it = lab.it; | ||
var before = lab.before; | ||
var beforeEach = lab.beforeEach; | ||
var after = lab.after; | ||
var afterEach = lab.afterEach; | ||
var expect = require('lab').expect; | ||
|
||
var getExtensions = require('../lib/helpers').getExtensions; | ||
|
||
test('should return the argument if it is an object', function(t){ | ||
var obj = {}; | ||
t.equal(getExtensions(obj), obj, 'should be the same object'); | ||
t.end(); | ||
}); | ||
describe('getExtensions', function(){ | ||
|
||
it('should return the argument if it is an object', function(done){ | ||
var obj = {}; | ||
expect(getExtensions(obj)).to.equal(obj); | ||
done(); | ||
}); | ||
|
||
test('should return undefined if argument is not an object', function(t){ | ||
var fn = function(){}; | ||
t.deepEqual(getExtensions(fn), undefined, 'should be a undefined'); | ||
t.end(); | ||
it('should return undefined if argument is not an object', function(done){ | ||
var fn = function(){}; | ||
expect(getExtensions(fn)).to.equal(undefined); | ||
done(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.