title: Why is the promise still pending?
body: <p>The following code returns:</p>
  
  <pre><code>output.isPending?: true
  output.isRejected?: false
  output.isFulfilled?: false 
  </code></pre>
  
  <p>Why? I was expecting <code>output.isRejected</code> to be <code>true</code>.</p>
  
  <pre><code>&lt;html&gt;
  
  &lt;head&gt;
      &lt;script src="http://cdnjs.cloudflare.com/ajax/libs/q.js/0.9.7/q.js"&gt;&lt;/script&gt;
      &lt;script src="http://jasmine.github.io/2.3/lib/jasmine.js"&gt;&lt;/script&gt;
  &lt;/head&gt;
  
  &lt;body&gt;
  &lt;/body&gt;
  &lt;script&gt;
  var output, bar;
  
  bar = {
      doSomethingAsync: function() {
          var d = Q.defer();
          d.resolve('result');
          return d.promise;
      }
  };
  
  function Foo(bar) {
      this._bar = bar;
  
      this.go = function() {
          var deferred = Q.defer();
          this._bar.doSomethingAsync()
              .then(onSuccess.bind(this, deferred));
  
          return deferred.promise;
      }
  };
  
  function onSuccess(deferred, result) {
      deferred.reject();
  }
  
  output = new Foo(bar).go()
      .finally(function() {
          console.log('output.isPending?:', output.isPending());
          console.log('output.isRejected?:', output.isRejected());
          console.log('output.isFulfilled?:', output.isFulfilled());
      });
  &lt;/script&gt;
  
  &lt;/html&gt;
  </code></pre>