06 October 2020, 01:20 PM
Expanding API test coverage through a pipeline
As developers and QAs, we’re concerned about to create the maximum test coverage for our API’s through unit and integration tests (shift-left test) using mocks to support a better strategy and removing dependencies. However, to have a great breadth of test coverage we need to think about more types of testing and, mainly, how can we execute them applied to a pipeline to deliver our APIs through a Continuous Delivery or Continuous Deployment strategy following their test pyramid to have faster feedback about our application health.
I'll mix the presentation with slides, to give the background about the system under tests and the different test types we can break down into a pipeline: health-check test, contract test, e2e test and, functional test. After that, I'll show a hands-on in how to create the automated tests for these 4 different types and which design patterns and approaches we can apply in order to have less maintenance and a lightweight framework.
I’ll use the following stack: Java, Rest-Assured, JUnit 5, Lombok, Log4J, JavaFaker, GitLab CI and Maven.