title: How can I create an observable with a delay
body: <h2>Question</h2>
  
  <p>For testing purposes, I'm creating <code>Observable</code> objects that replace the observable that would be returned by an actual http call with <code>Http</code>.</p>
  
  <p>My observable is created with the following code:</p>
  
  <pre class="lang-ts prettyprint-override"><code>fakeObservable = Observable.create(obs =&gt; {
    obs.next([1, 2, 3]);
    obs.complete();
  });
  </code></pre>
  
  <p>The thing is, this observable emits immediatly. Is there a way to add a custom delay to its emission?</p>
  
  <hr>
  
  <h2>Track</h2>
  
  <p>I tried this:</p>
  
  <pre class="lang-ts prettyprint-override"><code>fakeObservable = Observable.create(obs =&gt; {
    setTimeout(() =&gt; {
      obs.next([1, 2, 3]);
      obs.complete();
    }, 100);
  });
  </code></pre>
  
  <p>But it doesn't seem to work.</p>