title: How to write jasmine test to check update
body: <p>I'm trying to write jasmine test to check is view changing time or not</p>
  
  <pre><code>it 'ticks the time', -&gt;
    @time = parseInt($('#timer h1').text())
    setTimeout (-&gt;
      @after = parseInt($('#timer h1').text())
      expect(@time).toBeLessThan(@after)
    ), 1000
  </code></pre>
  
  <p>The problem is that when time of <code>setTimeout</code> is up the <code>jasmine</code> is already finished his job, no html code on page related to this test at that moment.</p>