konacha-chai-matchers 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  module Konacha
2
2
  module Chai
3
3
  module Matchers
4
- VERSION = "0.0.11"
4
+ VERSION = "0.0.12"
5
5
  end
6
6
  end
7
7
  end
@@ -1,4 +1,4 @@
1
- // Generated by CoffeeScript 1.3.3
1
+ // Generated by CoffeeScript 1.3.2
2
2
  (function() {
3
3
 
4
4
  (function(chaiChanges) {
@@ -37,7 +37,7 @@
37
37
  }
38
38
  }
39
39
  result = val();
40
- isPromise = typeof result.then === 'function';
40
+ isPromise = (typeof result === 'object') && (typeof result.then === 'function');
41
41
  if (((typeof DS !== "undefined" && DS !== null ? DS.Model : void 0) != null) && result instanceof DS.Model) {
42
42
  isPromise = false;
43
43
  }
@@ -62,8 +62,10 @@
62
62
  }
63
63
  };
64
64
  newPromise = result.then(promiseCallback, promiseCallback);
65
+ if (newPromise != null ? newPromise.then : void 0) {
66
+ this.then = newPromise.then;
67
+ }
65
68
  flag(this, 'object', newPromise);
66
- this.then = newPromise.then;
67
69
  } else {
68
70
  for (_j = 0, _len1 = definedActions.length; _j < _len1; _j++) {
69
71
  action = definedActions[_j];
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: konacha-chai-matchers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: