A landing page for information about Mockito framework, a mocking framework for unit tests written in Java.
Mockito is an open-source testing framework for Java. It allows the creation of mock objects in automated unit tests for the purpose of Test-driven Development (TDD) or Behavior-driven Development (BDD). Mockito helps in creating tests that are readable and produces clean verification errors.
0 / day
0 / day
0 pages per visit
Domain Rating
Domain Authority
Citation Level
English, etc
Easily create mock objects of interfaces and classes.
Use annotations like @Mock, @Spy, @InjectMocks for cleaner code.
Define the behavior of mock objects with stubbing.
Verify the interactions with mock objects.
Use argument matchers for flexible verification or stubbing.
Partially mock objects by spying on real instances.
Support for Behavior-driven Development style tests.
Define custom answers for stubbing calls.
Seamless integration with JUnit and TestNG.
Extend Mockito with custom plugins and extensions.
Mockito is released under the MIT License.
Mockito has a vibrant community of developers and contributors.
Comprehensive documentation is available for users to get started with Mockito.
Mockito's source code is hosted on GitHub, allowing for easy collaboration and version control.
Mockito welcomes contributions from the community, including bug reports, feature requests, and code contributions.
Mockito is compatible with Java 8 and above.
Mockito is designed to be lightweight and fast, ensuring minimal impact on test execution time.
Security headers report is a very important part of user data protection. Learn more about http headers for mockito.org