Spring boot 2 with Junit 5 and Mockito 2 for unit testing and integration test

Here we will explain to use Junit 5 and Mockito 2 with Spring boot 2 when it comes to unit testing and integration tests .

mockito-junit5-logo3-horiz.png

Continue reading

Advertisements

Spring boot with embedded PostgreSQL for DAO integration/unit testing and local development

Here we will go through how to use embedded PostgreSQL in you local development environment plus how to use it for DAO integration/unit testing if you have are using PostgreSQL as your production database , you DAO testing should use the same database as your production one to have behavior consistency and same environment precondition.

Continue reading

Spring boot integration test with cucumber and Jenkins pipeline

Here I am sharing how you can integrate cucumber for behavior driven testing with spring boot integration test and how you collect the reports in Jenkins pipeline.

In a sample spring boot app generated from my custom spring boot archetype we will show a small integration test suite with cucumber and spring boot.

Continue reading

Implement Retry in Unit test

If you are doing an integration test or sanity testing for real application endpoints in continuous delivery process where you hot deploy the application and and you want to trigger some checkups and sanity testing part of your delivery pipeline , how you can add retry logic with delay to unit testing and to your integration test ?

Continue reading