lib/reporters/base.js
function errorDiff(actual, expected) {
  return diff
    .diffWordsWithSpace(actual, expected)
    .map(function(str) {
      if (str.added) {
        return colorLines('diff added', str.value);
      }
      if (str.removed) {
        return colorLines('diff removed', str.value);
      }
      return str.value;
    })
    .join('');
}
function errorDiff(actual, expected) {
  return diff
    .diffWordsWithSpace(actual, expected)
    .map(function(str) {
      if (str.added) {
        return colorLines('diff added', str.value);
      }
      if (str.removed) {
        return colorLines('diff removed', str.value);
      }
      return str.value;
    })
    .join('');
}
function errorDiff ( actual , expected ) { return diff . diffWordsWithSpace ( actual , expected ) . map ( function ( str ) { if ( str . added ) { return colorLines ( 'diff added' , str . value ) ; } if ( str . removed ) { return colorLines ( 'diff removed' , str . value ) ; } return str . value ; } ) . join ( '' ) ; }
Returns character diff for `err`.

@private
@param {String} actual
@param {String} expected
@return {string} the diff
Returns character diff for err .