Test cleanup and fixes [i-l]
This commit is contained in:
@ -1,20 +1,16 @@
|
||||
const expect = require('expect');
|
||||
const isPromiseLike = require('./isPromiseLike.js');
|
||||
|
||||
|
||||
test('isPromiseLike is a Function', () => {
|
||||
test('isPromiseLike is a Function', () => {
|
||||
expect(isPromiseLike).toBeInstanceOf(Function);
|
||||
});
|
||||
t.equal(isPromiseLike({
|
||||
test('Returns true for a promise-like object', () => {
|
||||
expect(isPromiseLike({
|
||||
then: function() {
|
||||
return '';
|
||||
}
|
||||
}), true, 'Returns true for a promise-like object');
|
||||
test('Returns false for null', () => {
|
||||
expect(isPromiseLike(null), false).toBe()
|
||||
})).toBeTruthy();
|
||||
});
|
||||
test('Returns false for an empty object', () => {
|
||||
expect(isPromiseLike({}), false).toBe()
|
||||
test('Returns false for an empty object', () => {
|
||||
expect(isPromiseLike({})).toBeFalsy();
|
||||
});
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user