diff options
| author | Andres Ornelas | 2010-07-27 15:43:14 -0700 | 
|---|---|---|
| committer | Andres Ornelas | 2010-07-27 15:43:14 -0700 | 
| commit | da95010350882d9e13b5e461fb4a1e05bc7d065c (patch) | |
| tree | 2d97049da8cb268dc0c4bca85e5908f6ac1b5d58 /src/scenario/Future.js | |
| parent | b42072733c3afd03a49457d88ffed28ebe55655e (diff) | |
| download | angular.js-da95010350882d9e13b5e461fb4a1e05bc7d065c.tar.bz2 | |
stable before refactoring
Diffstat (limited to 'src/scenario/Future.js')
| -rw-r--r-- | src/scenario/Future.js | 29 | 
1 files changed, 2 insertions, 27 deletions
diff --git a/src/scenario/Future.js b/src/scenario/Future.js index c718bba2..6c90df9d 100644 --- a/src/scenario/Future.js +++ b/src/scenario/Future.js @@ -6,11 +6,12 @@ function Future(name, behavior) {  }  Future.prototype = { -  fulfill: function(value){ +  fulfill: function(value) {      this.fulfilled = true;      this.value = value;    }  }; +  function Matcher(future, logger) {    var self = this;    this.logger = logger; @@ -32,29 +33,3 @@ Matcher.addMatcher = function(name, matcher){  };  Matcher.addMatcher('toEqual', function(a,b){ return a == b; }); - -/* - -function future(name, behavior) { -  return new Future(name, behavior); -}; - -function repeater(selector) { -  var repeaterFuture = future('repeater ' + selector, function(done) { -    done($(selector)); -  }); - -  repeaterFuture.count =  function(){ -    return future(repeaterFuture.name + ' count', function(done) { -      done(repeaterFuture.value.size()); -    }); -  }; - -  return repeaterFuture; -} - -function expectX(future) { -  return new Matcher(future, window.alert); -} - - */
\ No newline at end of file  | 
