mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-14 12:47:49 +00:00
Keep skipping placeholder tests for modularized builds.
This commit is contained in:
20
test/test.js
20
test/test.js
@@ -776,6 +776,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
test('should support placeholders', 4, function() {
|
test('should support placeholders', 4, function() {
|
||||||
|
if (!isModularize) {
|
||||||
var object = {},
|
var object = {},
|
||||||
bound = _.bind(fn, object, _, 'b', _);
|
bound = _.bind(fn, object, _, 'b', _);
|
||||||
|
|
||||||
@@ -783,6 +784,10 @@
|
|||||||
deepEqual(bound('a'), [object, 'a', 'b', undefined]);
|
deepEqual(bound('a'), [object, 'a', 'b', undefined]);
|
||||||
deepEqual(bound('a', 'c', 'd'), [object, 'a', 'b', 'c', 'd']);
|
deepEqual(bound('a', 'c', 'd'), [object, 'a', 'b', 'c', 'd']);
|
||||||
deepEqual(bound(), [object, undefined, 'b', undefined]);
|
deepEqual(bound(), [object, undefined, 'b', undefined]);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
skipTest(4);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
test('should create a function with a `length` of `0`', 2, function() {
|
test('should create a function with a `length` of `0`', 2, function() {
|
||||||
@@ -973,11 +978,16 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (!isModularize) {
|
||||||
var bound = _.bindKey(object, 'fn', _, 'b', _);
|
var bound = _.bindKey(object, 'fn', _, 'b', _);
|
||||||
deepEqual(bound('a', 'c'), ['a', 'b', 'c']);
|
deepEqual(bound('a', 'c'), ['a', 'b', 'c']);
|
||||||
deepEqual(bound('a'), ['a', 'b', undefined]);
|
deepEqual(bound('a'), ['a', 'b', undefined]);
|
||||||
deepEqual(bound('a', 'c', 'd'), ['a', 'b', 'c', 'd']);
|
deepEqual(bound('a', 'c', 'd'), ['a', 'b', 'c', 'd']);
|
||||||
deepEqual(bound(), [undefined, 'b', undefined]);
|
deepEqual(bound(), [undefined, 'b', undefined]);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
skipTest(4);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}());
|
}());
|
||||||
|
|
||||||
@@ -1803,11 +1813,16 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
test('should support placeholders', 4, function() {
|
test('should support placeholders', 4, function() {
|
||||||
|
if (!isModularize) {
|
||||||
var curried = _.curry(fn);
|
var curried = _.curry(fn);
|
||||||
deepEqual(curried(1)(_, 3)(_, 4)(2), [1, 2, 3, 4]);
|
deepEqual(curried(1)(_, 3)(_, 4)(2), [1, 2, 3, 4]);
|
||||||
deepEqual(curried(_, 2)(1)(_, 4)(3), [1, 2, 3, 4]);
|
deepEqual(curried(_, 2)(1)(_, 4)(3), [1, 2, 3, 4]);
|
||||||
deepEqual(curried(_, _, 3)(_, 2)(_, 4)(1), [1, 2, 3, 4]);
|
deepEqual(curried(_, _, 3)(_, 2)(_, 4)(1), [1, 2, 3, 4]);
|
||||||
deepEqual(curried(_, _, _, 4)(_, _, 3)(_, 2)(1), [1, 2, 3, 4]);
|
deepEqual(curried(_, _, _, 4)(_, _, 3)(_, 2)(1), [1, 2, 3, 4]);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
skipTest(4);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
test('should return a function with a `length` of `0`', 6, function() {
|
test('should return a function with a `length` of `0`', 6, function() {
|
||||||
@@ -6864,6 +6879,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
test('`_.' + methodName + '` should support placeholders', 4, function() {
|
test('`_.' + methodName + '` should support placeholders', 4, function() {
|
||||||
|
if (!isModularize) {
|
||||||
var fn = function() { return slice.call(arguments); },
|
var fn = function() { return slice.call(arguments); },
|
||||||
par = func(fn, _, 'b', _);
|
par = func(fn, _, 'b', _);
|
||||||
|
|
||||||
@@ -6877,6 +6893,10 @@
|
|||||||
par = func(fn, _, 'c', _);
|
par = func(fn, _, 'c', _);
|
||||||
deepEqual(par('a', 'b', 'd'), ['a', 'b', 'c', 'd']);
|
deepEqual(par('a', 'b', 'd'), ['a', 'b', 'c', 'd']);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
skipTest(4);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
test('`_.' + methodName + '` should not alter the `this` binding', 3, function() {
|
test('`_.' + methodName + '` should not alter the `this` binding', 3, function() {
|
||||||
|
|||||||
Reference in New Issue
Block a user