Sha256: bc1a0c796463f344c42e5e6a5035f7f0deb0e75d6bb6d9d628180ec188bda9a0

Contents?: true

Size: 1004 Bytes

Versions: 6

Compression:

Stored size: 1004 Bytes

Contents

/** JasmineReporters.reporter
 *    Base object that will get called whenever a Spec, Suite, or Runner is done.  It is up to
 *    descendants of this object to do something with the results (see json_reporter.js)
 *
 * @deprecated
 */
jasmine.Reporters = {};

/**
 * @deprecated
 * @param callbacks
 */
jasmine.Reporters.reporter = function(callbacks) {
  /**
   * @deprecated
   * @param callbacks
   */
  var that = {
    callbacks: callbacks || {},

    doCallback: function(callback, results) {
      if (callback) {
        callback(results);
      }
    },

    reportRunnerResults: function(runner) {
      that.doCallback(that.callbacks.runnerCallback, runner);
    },
    reportSuiteResults:  function(suite) {
      that.doCallback(that.callbacks.suiteCallback, suite);
    },
    reportSpecResults:   function(spec) {
      that.doCallback(that.callbacks.specCallback, spec);
    },
    log: function (str) {
      if (console && console.log) console.log(str);
    }
  };

  return that;
};

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
evergreen-0.1 lib/jasmine/src/Reporters.js
jasnode-0.4.3.0 jasmine/src/Reporters.js
jasnode-0.4.2.0 jasmine/src/Reporters.js
jasnode-0.4.1.0 jasmine/src/Reporters.js
jasnode-0.4.0.0 jasmine/src/Reporters.js
jasnode-0.2.0.0 jasmine/src/Reporters.js