Last updated: May 25, 2022

Mockito

Mockito is the one that is used to do significant unit testing of the java application. It works on the process of mocking where a dummy functionality is added to the test case. In this, a mock object is used which acts as a proxy for the actual implementation. Let's understand the concept through this section.
Mockito Introduction and Features EASY
In this blog, we will be discussing Mockito and its features. We will be writing a unit test case using Mockito.
Author Anjali
0 upvotes
Getting Started With Mockito EASY
In this blog, we will be discussing Mockito installation, setup in a project, and writing basic tests.
Author Anjali
6 upvotes
Mockito Integration in JUnit EASY
In this article, we will explore the integration of the Mockito mocking framework in the JUnit testing framework to perform unit tests in Java.
Testing Behavior With Mockito EASY
In this article, we will learn about testing behavior using When and Verify methods in Mockito with the help of examples.
Expecting Calls - Mockito EASY
In this blog, we will learn how to manage the number of calls made on a particular method.
Varying Calls In Mockito EASY
In this article, we will discuss three essential methods available in Mockito; atLeast, atLeastOnce, and atMost, which help us vary the expected call counts while writing a unit test.
Argument Matcher
The article covers argument matchers, method type and method name along with description.
Custom Matchers EASY
This article will discuss the Custom Matchers or the Custom Argument Matchers using the Mockito Framework. We will further look at an example of Custom Argument Matchers.
Testing exceptions EASY
This blog discusses the various Mockito Annotations with the help of practical examples.
Ordered Verification
In this blog, we will learn about the ways to check whether the order of method calls is in order or not using Inorder object.
Stubbing Methods And Returning Default Values EASY
This article explains the Stubbing Methods in mockito and returning default values.
Capturing Arguments in Mockito EASY
This article explains the use and the important methods of the Mockito ArgumentCaptor.
Testing Callback EASY
This blog discusses the various approach to test callbacks in Mockito.
Spying EASY
This blog discusses the theoretical and practical implementation of Spies in Mockito.
Resetting Mocks and clearing invocations EASY
This blog discusses the theoretical and practical implementation of resetting mocks and clearing invocations.
Mockito BDD EASY
This blog discusses the theoretical and practical implementation of Mockito BDD.
Mockito Timeouts
The article discusses the timeout option in mockito that may be used to see if a method is called within a certain amount of time.
Best Practices in Mockito
We will discuss some of the best practices when mocking in mockito and to bring the best out of the testing framework.
Mock vs Stub vs Spy EASY
The article covers the difference between Mock, Stub and Spy. We will see implementation of these objects through practical implementation
Mockito vs. EasyMock EASY
In this article, we will learn about the concepts and some key differences between two of the most popular mocking frameworks in Java, Mockito and EasyMock, with some examples.
Mockito With Java 8 EASY
In this article, we will explore the features available in the powerful combination of Mockito and Java 8 with the help of examples.