title: Mocking CountDownTimer and Handler
body: <p>I'm using <strong>Mockito</strong> and <strong>PowerMockito</strong> to write my Unit Test on Android. </p>
  
  <p>I've managed to work with almost all by back stuff, but I'm stuck with the <a href="https://developer.android.com/reference/android/os/CountDownTimer.html" rel="noreferrer"><code>CountDownTimer</code></a> and <a href="https://developer.android.com/reference/android/os/Handler.html" rel="noreferrer"><code>Handler</code></a>. </p>
  
  <p>I'm able to mock a subclass of <code>CountDownTimer</code>, but I'm not able to mock it's <strong>final method</strong> like <a href="https://developer.android.com/reference/android/os/CountDownTimer.html#cancel()" rel="noreferrer"><code>cancel()</code></a>, so each time the <code>cancel()</code> method is called, the test runner report a <code>java.lang.RuntimeException: Method cancel in android.os.CountDownTimer not mocked. See ...</code></p>
  
  <p><strong>Do anyone have a solution for this without using Robolectric?</strong> </p>