JUnit Custom Display Name Generator API 1. Overview JUnit 5 has good support for customizing test class and test method names. In this quick tutorial, we’ll see how we can use JUnit 5 custom display name generators via the @DisplayNameGeneration annotation. 2. Display Name Generation We can configure custom display… Continue Reading junit-custom-display-name-generator

JUnit 5 @Test Annotation 1. Overview In this article, we’ll make a quick review of JUnit’s @Test annotation. This annotation provides a powerful tool for performing unit and regression testing. 2. Maven Configuration To use the latest version of JUnit 5, we’ll need to add the following Maven dependency: <dependency>… Continue Reading junit-5-test-annotation

Mockito and JUnit 5 – Using ExtendWith 1. Introduction In this quick article, we’ll show how to integrate Mockito with the JUnit 5 extension model. To learn more about the JUnit 5 extension model, have a look at this article. First, we’ll show how to create an extension that automatically creates mock… Continue Reading mockito-junit-5-extension