Adjust "provided"/"given" use. [ci skip]

This commit is contained in:
John-David Dalton
2016-02-07 22:41:07 -08:00
parent 349c627110
commit d790a1b3c6
2 changed files with 45 additions and 45 deletions

View File

@@ -2341,7 +2341,7 @@
* @private
* @param {Function} func The function to delay.
* @param {number} wait The number of milliseconds to delay invocation.
* @param {Object} args The arguments provide to `func`.
* @param {Object} args The arguments to provide to `func`.
* @returns {number} Returns the timer id.
*/
function baseDelay(func, wait, args) {
@@ -2586,7 +2586,7 @@
/**
* The base implementation of `_.functions` which creates an array of
* `object` function property names filtered from those provided.
* `object` function property names filtered from `props`.
*
* @private
* @param {Object} object The object to inspect.
@@ -5051,7 +5051,7 @@
}
/**
* Checks if the provided arguments are from an iteratee call.
* Checks if the given arguments are from an iteratee call.
*
* @private
* @param {*} value The potential iteratee value argument.
@@ -5459,7 +5459,7 @@
/**
* Creates an array of unique `array` values not included in the other
* provided arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* given arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons.
*
* @static
@@ -5939,8 +5939,8 @@
}
/**
* Creates an array of unique values that are included in all of the provided
* arrays using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* Creates an array of unique values that are included in all given arrays
* using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons.
*
* @static
@@ -6105,7 +6105,7 @@
}
/**
* Removes all provided values from `array` using
* Removes all given values from `array` using
* [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons.
*
@@ -6662,8 +6662,8 @@
}
/**
* Creates an array of unique values, in order, from all of the provided arrays
* using [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* Creates an array of unique values, in order, from all given arrays using
* [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons.
*
* @static
@@ -6874,7 +6874,7 @@
}
/**
* Creates an array excluding all provided values using
* Creates an array excluding all given values using
* [`SameValueZero`](http://ecma-international.org/ecma-262/6.0/#sec-samevaluezero)
* for equality comparisons.
*
@@ -6897,7 +6897,7 @@
/**
* Creates an array of unique values that is the [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference)
* of the provided arrays.
* of the given arrays.
*
* @static
* @memberOf _
@@ -7923,7 +7923,7 @@
* Reduces `collection` to a value which is the accumulated result of running
* each element in `collection` through `iteratee`, where each successive
* invocation is supplied the return value of the previous. If `accumulator`
* is not provided the first element of `collection` is used as the initial
* is not given the first element of `collection` is used as the initial
* value. The iteratee is invoked with four arguments:
* (accumulator, value, index|key, collection).
*
@@ -10785,7 +10785,7 @@
/**
* Creates an object that inherits from the `prototype` object. If a `properties`
* object is provided its own enumerable properties are assigned to the created object.
* object is given its own enumerable properties are assigned to the created object.
*
* @static
* @memberOf _
@@ -12551,7 +12551,7 @@
* in "interpolate" delimiters, HTML-escape interpolated data properties in
* "escape" delimiters, and execute JavaScript in "evaluate" delimiters. Data
* properties may be accessed as free variables in the template. If a setting
* object is provided it takes precedence over `_.templateSettings` values.
* object is given it takes precedence over `_.templateSettings` values.
*
* **Note:** In the development build `_.template` utilizes
* [sourceURLs](http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl)
@@ -13229,9 +13229,9 @@
}
/**
* Creates a function that returns the result of invoking the provided
* functions with the `this` binding of the created function, where each
* successive invocation is supplied the return value of the previous.
* Creates a function that returns the result of invoking the given functions
* with the `this` binding of the created function, where each successive
* invocation is supplied the return value of the previous.
*
* @static
* @memberOf _
@@ -13252,7 +13252,7 @@
/**
* This method is like `_.flow` except that it creates a function that
* invokes the provided functions from right to left.
* invokes the given functions from right to left.
*
* @static
* @memberOf _
@@ -13272,7 +13272,7 @@
var flowRight = createFlow(true);
/**
* This method returns the first argument provided to it.
* This method returns the first argument given to it.
*
* @static
* @memberOf _
@@ -13824,7 +13824,7 @@
}
/**
* Generates a unique ID. If `prefix` is provided the ID is appended to it.
* Generates a unique ID. If `prefix` is given the ID is appended to it.
*
* @static
* @memberOf _

View File

@@ -948,7 +948,7 @@
}
});
QUnit.test('should return provided `lodash` instances', function(assert) {
QUnit.test('should return the given `lodash` instances', function(assert) {
assert.expect(1);
if (!isNpm) {
@@ -1092,7 +1092,7 @@
assert.deepEqual(capped('a', 'b', 'c', 'd'), ['a', 'b']);
});
QUnit.test('should use `func.length` if `n` is not provided', function(assert) {
QUnit.test('should use `func.length` if `n` is not given', function(assert) {
assert.expect(1);
var capped = _.ary(fn);
@@ -1125,7 +1125,7 @@
assert.deepEqual(actual, expected);
});
QUnit.test('should work when provided less than the capped number of arguments', function(assert) {
QUnit.test('should work when given less than the capped number of arguments', function(assert) {
assert.expect(1);
var capped = _.ary(fn, 3);
@@ -1334,7 +1334,7 @@
assert.deepEqual(actual, expected);
});
QUnit.test('should return an empty array when no keys are provided', function(assert) {
QUnit.test('should return an empty array when no keys are given', function(assert) {
assert.expect(2);
assert.deepEqual(_.at(array), []);
@@ -1348,7 +1348,7 @@
assert.deepEqual(actual, ['d', 'a', 'c']);
});
QUnit.test('should work with a falsey `object` argument when keys are provided', function(assert) {
QUnit.test('should work with a falsey `object` argument when keys are given', function(assert) {
assert.expect(1);
var expected = lodashStable.map(falsey, lodashStable.constant(Array(4)));
@@ -3433,7 +3433,7 @@
return slice.call(arguments);
}
QUnit.test('should curry based on the number of arguments provided', function(assert) {
QUnit.test('should curry based on the number of arguments given', function(assert) {
assert.expect(3);
var curried = _.curry(fn),
@@ -3565,7 +3565,7 @@
return slice.call(arguments);
}
QUnit.test('should curry based on the number of arguments provided', function(assert) {
QUnit.test('should curry based on the number of arguments given', function(assert) {
assert.expect(3);
var curried = _.curryRight(fn),
@@ -5037,7 +5037,7 @@
assert.deepEqual(_.fill(array, 'a'), ['a', 'a', 'a']);
});
QUnit.test('should use `undefined` for `value` if not provided', function(assert) {
QUnit.test('should use `undefined` for `value` if not given', function(assert) {
assert.expect(2);
var array = [1, 2, 3],
@@ -5666,7 +5666,7 @@
assert.notStrictEqual(func(noop), noop);
});
QUnit.test('`_.' + methodName + '` should return an identity function when no arguments are provided', function(assert) {
QUnit.test('`_.' + methodName + '` should return an identity function when no arguments are given', function(assert) {
assert.expect(3);
var combined = func();
@@ -6968,7 +6968,7 @@
QUnit.module('lodash.identity');
(function() {
QUnit.test('should return the first argument provided', function(assert) {
QUnit.test('should return the first argument given', function(assert) {
assert.expect(1);
var object = { 'name': 'fred' };
@@ -13377,7 +13377,7 @@
QUnit.module('lodash.memoize');
(function() {
QUnit.test('should memoize results based on the first argument provided', function(assert) {
QUnit.test('should memoize results based on the first argument given', function(assert) {
assert.expect(2);
var memoized = _.memoize(function(a, b, c) {
@@ -14587,7 +14587,7 @@
assert.expect(8);
function message(func, chain) {
return (func === _ ? 'lodash' : 'provided') + ' function should ' + (chain ? '' : 'not ') + 'chain';
return (func === _ ? 'lodash' : 'given') + ' function should ' + (chain ? '' : 'not ') + 'chain';
}
lodashStable.each([_, Wrapper], function(func) {
@@ -14620,7 +14620,7 @@
});
});
QUnit.test('should not extend lodash when an `object` is provided with an empty `options` object', function(assert) {
QUnit.test('should not extend lodash when an `object` is given with an empty `options` object', function(assert) {
assert.expect(1);
_.mixin({ 'a': noop }, {});
@@ -14785,7 +14785,7 @@
assert.deepEqual(over(5, 10, 18), [10, 100, 18]);
});
QUnit.test('should not transform any arguments if no transforms are provided', function(assert) {
QUnit.test('should not transform any arguments if no transforms are given', function(assert) {
assert.expect(1);
var over = _.overArgs(fn);
@@ -16521,7 +16521,7 @@
assert.deepEqual(array, ['b']);
});
QUnit.test('should return an empty array when no indexes are provided', function(assert) {
QUnit.test('should return an empty array when no indexes are given', function(assert) {
assert.expect(4);
var array = ['a', 'b', 'c'],
@@ -16576,7 +16576,7 @@
assert.deepEqual(actual, [undefined]);
});
QUnit.test('should work with a falsey `array` argument when keys are provided', function(assert) {
QUnit.test('should work with a falsey `array` argument when keys are given', function(assert) {
assert.expect(1);
var values = falsey.slice(),
@@ -16599,7 +16599,7 @@
(function() {
var array = Array(1000);
QUnit.test('should return `0` or `1` when arguments are not provided', function(assert) {
QUnit.test('should return `0` or `1` when no arguments are given', function(assert) {
assert.expect(1);
var actual = lodashStable.map(array, function() {
@@ -16721,14 +16721,14 @@
return isRange ? range : range.reverse();
}
QUnit.test('`_.' + methodName + '` should infer the sign of `step` when provided only an `end` argument', function(assert) {
QUnit.test('`_.' + methodName + '` should infer the sign of `step` when only `end` is given', function(assert) {
assert.expect(2);
assert.deepEqual(func(4), resolve([0, 1, 2, 3]));
assert.deepEqual(func(-4), resolve([0, -1, -2, -3]));
});
QUnit.test('`_.' + methodName + '` should infer the sign of `step` when provided only a `start` and `end` argument', function(assert) {
QUnit.test('`_.' + methodName + '` should infer the sign of `step` when only `start` and `end` are given', function(assert) {
assert.expect(2);
assert.deepEqual(func(1, 5), resolve([1, 2, 3, 4]));
@@ -16850,7 +16850,7 @@
assert.deepEqual(actual, expected);
});
QUnit.test('should not rearrange arguments when no indexes are provided', function(assert) {
QUnit.test('should not rearrange arguments when no indexes are given', function(assert) {
assert.expect(2);
var rearged = _.rearg(fn);
@@ -17070,7 +17070,7 @@
assert.strictEqual(actual, undefined);
});
QUnit.test('`_.' + methodName + '` should return `undefined` for empty collections when no `accumulator` is provided (test in IE > 9 and modern browsers)', function(assert) {
QUnit.test('`_.' + methodName + '` should return `undefined` for empty collections when no `accumulator` is given (test in IE > 9 and modern browsers)', function(assert) {
assert.expect(2);
var array = [],
@@ -20336,7 +20336,7 @@
assert.deepEqual(options, {});
});
QUnit.test('should not modify `_.templateSettings` when `options` are provided', function(assert) {
QUnit.test('should not modify `_.templateSettings` when `options` are given', function(assert) {
assert.expect(2);
var data = { 'a': 1 };
@@ -21770,7 +21770,7 @@
Foo.prototype.constructor = Foo;
});
QUnit.test('should create an empty object when provided a falsey `object` argument', function(assert) {
QUnit.test('should create an empty object when given a falsey `object` argument', function(assert) {
assert.expect(1);
var expected = lodashStable.map(falsey, alwaysEmptyObject);
@@ -22899,7 +22899,7 @@
assert.deepEqual(actual, [1]);
});
QUnit.test('`_.' + methodName + '` should return a new array when a single array is provided', function(assert) {
QUnit.test('`_.' + methodName + '` should return a new array when a single array is given', function(assert) {
assert.expect(1);
var array = [1];
@@ -24052,7 +24052,7 @@
assert.ok(lodashStable.isArray(actual), '_.' + methodName + ' returns an array');
var isPull = methodName == 'pull' || methodName == 'pullAll';
assert.strictEqual(actual === array, isPull, '_.' + methodName + ' should ' + (isPull ? '' : 'not ') + 'return the provided array');
assert.strictEqual(actual === array, isPull, '_.' + methodName + ' should ' + (isPull ? '' : 'not ') + 'return the given array');
});
});