Should ensure callback is a function in _.isEqual.

Former-commit-id: b53f8e0ab1bafff395ff19cd069940ba6c37eb5f
This commit is contained in:
John-David Dalton
2013-04-05 08:59:09 -07:00
parent 5dc550a0ce
commit 8f3eeefafd
2 changed files with 10 additions and 5 deletions

View File

@@ -1386,6 +1386,14 @@
strictEqual(actual, false);
});
});
test('should ensure `callback` is a function', function() {
var array = [1, 2, 3],
eq = _.partial(_.isEqual, array),
actual = _.every([array, [1, 0, 3]], eq);
strictEqual(actual, false);
})
}());
/*--------------------------------------------------------------------------*/