Introduction

This is the The Maven Unit and Integration Test Guide (MaUI Test Guide) which describes the different options how to do unit- and integration testing with Maven in different situations. For example if you are writing a Maven Plugin or just developing different other modules.

This is no plugin or development project it is just a guide how to do unit and or integration tests in relationship with Maven.

Prerequisites

This guide requires that you already familiar with Maven and it's life-cycles etc. It will not explain how to configure a Maven Plugin or how to run a plugin etc. If you don't know Maven or it's basic usage i recommend you to read Maven: The Complete Reference or Maven by Example or other sources.

Definition of Terms

We distinguish between a so called in Module integration tests and a separated module with integration tests. The in module means to have the integration tests within the same module which contains the unit tests and your production code src/main/java. This approach is usually used if you have only a single module.

The separated module integration is mostly used if you have already a multiple module build. The result will be to have a supplemental module which contains the integration tests only.

Chapter Overview

This guide is separated into three chapters where the first is about Unit Testing with Maven, the second about Integration Testing with Maven and the last one is about Maven Plugin Integration Testing.