Verifying End-to-end Test Code Coverage using Jacoco Agent
Fact - End-to-end tests are critical if you want to make sure your software works as it should. To be 100% sure that you covered every (or almost every) possible branch in your business code, it is worth to check what code has been invoked after your E2E suite finished successfully.
Lifting functions to work with monads in Java
Functional Programming in Java
Stream and Optional classes - added to Java 8 - allow you to have some fun with functional programming. The problem is Java still misses quite a lot to be taken as a serious FP language.
Composing functions with java.util.function.Function.andThen() trick
In this article, I am going to present you a simple trick that will make using java.util.function.Function.andThen() more useful.
1Exception-free code using functional approach
Checked exceptions & Java 8
Defining custom exceptions (both checked and unchecked) is a common approach to handling errors in Java applications. It usually leads to creating a new class for every different type of error, marking methods with throws keyword or wrapping code with try-catch blocks.