title: How to get the number of times a mock is called in Mockito
body: <p>I'm using PowerMockito with Mockito to mock a few static classes. I want to get the number of times a particular mock object is called during run time so that I can use that count in verify times for another mock object.</p>
  
  <p>I need this because, the method I'm testing starts a thread and stops the thread after a second. My mocks are called several times in this 1 second. After the first mock is called, code branches and different mocks can be called. So, I want to compare the count of first mock with the count of other mocks.</p>
  
  <p>This is a legacy code. So I cannot make changes to actual code. I can only change test code.</p>