lib/nixt/expectations.js
function assertOut(key, expected, result) {
  var actual = result[key];
  var statement = expected instanceof RegExp
    ? expected.test(actual)
    : expected === actual;

  if (statement !== true) {
    var message = 'Expected ' + key +' to match "' + expected + '". Actual: "' + actual + '"';
    return error(result, message, expected, actual);
  }
}
function assertOut(key, expected, result) {
  var actual = result[key];
  var statement = expected instanceof RegExp
    ? expected.test(actual)
    : expected === actual;

  if (statement !== true) {
    var message = 'Expected ' + key +' to match "' + expected + '". Actual: "' + actual + '"';
    return error(result, message, expected, actual);
  }
}
function assertOut ( key , expected , result ) { var actual = result [ key ] ; var statement = expected instanceof RegExp ? expected . test ( actual ) : expected === actual ; if ( statement !== true ) { var message = 'Expected ' + key + ' to match "' + expected + '". Actual: "' + actual + '"' ; return error ( result , message , expected , actual ) ; } }
Assert stdout or stderr.

@param {String} stdout/stderr
@param {Mixed} expected
@param {Result} result
@returns {AssertionError|null}
@api private
Assert stdout or stderr .