title: How do I return different values on different calls to a mock?
body: <p>I have the following code which is getting the current counter value from DB. Then it updates the counter in DB and then again it retrieves the value.</p>
  
  <pre><code>int current = DBUtil.getCurrentCount();
  DBUtil.updateCount(50);// it updates the current count by adding 50
  int latest = DBUtil.getCurrentCount();
  </code></pre>
  
  <p>I want to mock the static methods in such a way that the first call should return 100 and the second call should return 150. How can I use PowerMockito to achieve this? I am using TestNG, Mockito along with PowerMock.</p>