Skip to content

Commit

Permalink
Merge pull request #911 from aaronsofaly/fix-plugin-utilities-documen…
Browse files Browse the repository at this point in the history
…tation

Fix plugin utilities documentation
  • Loading branch information
keithamus committed Jan 23, 2017
2 parents a64eb62 + 38d3cca commit 4b7b70c
Show file tree
Hide file tree
Showing 18 changed files with 20 additions and 18 deletions.
2 changes: 1 addition & 1 deletion lib/chai/utils/addChainableMethod.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ var call = Function.prototype.call,
apply = Function.prototype.apply;

/**
* ### addChainableMethod (ctx, name, method, chainingBehavior)
* ### .addChainableMethod(ctx, name, method, chainingBehavior)
*
* Adds a method to an object, such that the method can also be chained.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/addLengthGuard.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ var fnLengthDesc = Object.getOwnPropertyDescriptor(function () {}, 'length');
*/

/**
* # addLengthGuard(fn, assertionName, isChainable)
* ### .addLengthGuard(fn, assertionName, isChainable)
*
* Define `length` as a getter on the given uninvoked method assertion. The
* getter acts as a guard against chaining `length` directly off of an uninvoked
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/addMethod.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var proxify = require('./proxify');
var transferFlags = require('./transferFlags');

/**
* ### .addMethod (ctx, name, method)
* ### .addMethod(ctx, name, method)
*
* Adds a method to the prototype of an object.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/addProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ var isProxyEnabled = require('./isProxyEnabled');
var transferFlags = require('./transferFlags');

/**
* ### addProperty (ctx, name, getter)
* ### .addProperty(ctx, name, getter)
*
* Adds a property to the prototype of an object.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/compareByInspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
var inspect = require('./inspect');

/**
* ### .compareByInspect (mixed, mixed)
* ### .compareByInspect(mixed, mixed)
*
* To be used as a compareFunction with Array.prototype.sort. Compares elements
* using inspect instead of default behavior of using toString so that Symbols
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/expectTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

/**
* ### expectTypes(obj, types)
* ### .expectTypes(obj, types)
*
* Ensures that the object being tested against is of a valid type.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/flag.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

/**
* ### flag(object, key, [value])
* ### .flag(object, key, [value])
*
* Get or set a flag value on an object. If a
* value is provided it will be set, else it will
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/getActual.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

/**
* # getActual(object, [actual])
* ### .getActual(object, [actual])
*
* Returns the `actual` value for an Assertion.
*
Expand Down
4 changes: 3 additions & 1 deletion lib/chai/utils/inspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,14 @@ var config = require('../config');
module.exports = inspect;

/**
* ### .inspect(obj, [showHidden], [depth], [colors])
*
* Echoes the value of a value. Tries to print the value out
* in the best way possible given the different types.
*
* @param {Object} obj The object to print out.
* @param {Boolean} showHidden Flag that shows hidden (not enumerable)
* properties of objects.
* properties of objects. Default is false.
* @param {Number} depth Depth in which to descend in object. Default is 2.
* @param {Boolean} colors Flag to turn on ANSI escape codes to color the
* output. Default is false (no coloring).
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/isNaN.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

/**
* ### isNaN(value)
* ### .isNaN(value)
*
* Checks if the given value is NaN or not.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/isProxyEnabled.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ var config = require('../config');
*/

/**
* # isProxyEnabled()
* ### .isProxyEnabled()
*
* Helper function to check if Chai's proxy protection feature is enabled. If
* proxies are unsupported or disabled via the user's Chai config, then return
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/objDisplay.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ var inspect = require('./inspect');
var config = require('../config');

/**
* ### .objDisplay (object)
* ### .objDisplay(object)
*
* Determines if an object or an array matches
* criteria to be inspected in-line for error
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/overwriteChainableMethod.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var chai = require('../../chai');
var transferFlags = require('./transferFlags');

/**
* ### overwriteChainableMethod (ctx, name, method, chainingBehavior)
* ### .overwriteChainableMethod(ctx, name, method, chainingBehavior)
*
* Overwites an already existing chainable method
* and provides access to the previous function or
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/overwriteMethod.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var proxify = require('./proxify');
var transferFlags = require('./transferFlags');

/**
* ### overwriteMethod (ctx, name, fn)
* ### .overwriteMethod(ctx, name, fn)
*
* Overwites an already existing method and provides
* access to previous function. Must return function
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/overwriteProperty.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ var isProxyEnabled = require('./isProxyEnabled');
var transferFlags = require('./transferFlags');

/**
* ### overwriteProperty (ctx, name, fn)
* ### .overwriteProperty(ctx, name, fn)
*
* Overwites an already existing property getter and provides
* access to previous value. Must return function to use as getter.
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/proxify.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ var isProxyEnabled = require('./isProxyEnabled');
*/

/**
* # proxify(object)
* ### .proxify(object)
*
* Return a proxy of given object that throws an error when a non-existent
* property is read. By default, the root cause is assumed to be a misspelled
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
var flag = require('./flag');

/**
* # test(object, expression)
* ### .test(object, expression)
*
* Test and object for expression.
*
Expand Down
2 changes: 1 addition & 1 deletion lib/chai/utils/transferFlags.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*/

/**
* ### transferFlags(assertion, object, includeAll = true)
* ### .transferFlags(assertion, object, includeAll = true)
*
* Transfer all the flags for `assertion` to `object`. If
* `includeAll` is set to `false`, then the base Chai
Expand Down

0 comments on commit 4b7b70c

Please sign in to comment.