Sha256: 5e12c33bb5b564fa185b642c43580eaf570c61a002809413fe216772cad837d2

Contents?: true

Size: 876 Bytes

Versions: 40

Compression:

Stored size: 876 Bytes

Contents

getJasmineRequireObj().CallTracker = function() {

  function CallTracker() {
    var calls = [];

    this.track = function(context) {
      calls.push(context);
    };

    this.any = function() {
      return !!calls.length;
    };

    this.count = function() {
      return calls.length;
    };

    this.argsFor = function(index) {
      var call = calls[index];
      return call ? call.args : [];
    };

    this.all = function() {
      return calls;
    };

    this.allArgs = function() {
      var callArgs = [];
      for(var i = 0; i < calls.length; i++){
        callArgs.push(calls[i].args);
      }

      return callArgs;
    };

    this.first = function() {
      return calls[0];
    };

    this.mostRecent = function() {
      return calls[calls.length - 1];
    };

    this.reset = function() {
      calls = [];
    };
  }

  return CallTracker;
};

Version data entries

40 entries across 40 versions & 2 rubygems

Version Path
optimacms-0.1.61 spec/dummy/node_modules/bootstrap-tagsinput/lib/jasmine/src/core/CallTracker.js
upjs-rails-0.11.0 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.5 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.4 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.3 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.2 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.1 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.10.0 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.9.1 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.9.0 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.8.2 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.8.1 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.8.0 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.8 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.7 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.6 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.5 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.4 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.3 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js
upjs-rails-0.7.2 spec_app/vendor/assets/bower_components/jasmine/src/core/CallTracker.js