I am writing unit tests that test the thread safety of individual Java classes. I use Mocktio to set up the tests and verify the interactions in a multithreaded environment are done as per the expectations, and threads do not interfere with business expectations.
Are Mockito mocks thread-safe in that context? Can the mocked methods be called by many threads and the invocations will be counted correctly?
Yes, they are. Quoting mockito documentation.