mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-01 15:57:48 +00:00
Move getFuncName test.
This commit is contained in:
24
test/test.js
24
test/test.js
@@ -3474,18 +3474,6 @@
|
||||
assert.deepEqual(c(3), expected);
|
||||
assert.deepEqual(d(), expected);
|
||||
});
|
||||
|
||||
QUnit.test('should work when a function name matches function name on Object.prototype', function(assert) {
|
||||
assert.expect(1);
|
||||
|
||||
var curried = _.curry(function hasOwnProperty(a, b, c) {
|
||||
return [a, b, c];
|
||||
});
|
||||
|
||||
var expected = [1, 2, 3];
|
||||
|
||||
assert.deepEqual(curried(1)(2)(3), expected);
|
||||
});
|
||||
}());
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
@@ -3663,6 +3651,18 @@
|
||||
assert.deepEqual(actual, expected);
|
||||
});
|
||||
});
|
||||
|
||||
QUnit.test('`_.' + methodName + '` should work for function names that shadow those on `Object.prototype`', function(assert) {
|
||||
assert.expect(1);
|
||||
|
||||
var curried = _.curry(function hasOwnProperty(a, b, c) {
|
||||
return [a, b, c];
|
||||
});
|
||||
|
||||
var expected = [1, 2, 3];
|
||||
|
||||
assert.deepEqual(curried(1)(2)(3), expected);
|
||||
});
|
||||
});
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
|
||||
Reference in New Issue
Block a user