title: reactPHP promises executed synchoniously
body: <p>I'm trying to implement js-like promises with reactPHP.
  But for some reason methods executed synchronously, the <code>end_at</code> printed only after the promise is resolved.</p>
  
  <p>Code:</p>
  
  <pre><code>function iterate() {
  
  
      $deferred = new \React\Promise\Deferred();
  
      sleep(2);
  
      $deferred-&gt;resolve();
  
      return $deferred-&gt;promise();
  
  }
  
  Route::get('test/async', function() {
  
  
      echo "start execution at ".time()."&lt;br&gt;"; // this executed first
  
      iterate()-&gt;then(function($result) {
          echo "got result result at ". time() . "&lt;br&gt;"; // this is second
      }, function($error) {
  
      }, function ($finally) {
  
      });
  
  
      echo "end at " . time(); // this is executed only after then().
  
  
  }); 
  </code></pre>