<?xml version="1.0"?> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <modelVersion>4.0.0</modelVersion> <groupId>com.baeldung</groupId> <artifactId>java-mongodb</artifactId> <version>1.0-SNAPSHOT</version> <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>${junit.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>de.flapdoodle.embedmongo</groupId> <artifactId>de.flapdoodle.embedmongo</artifactId> <version>${flapdoodle.version}</version> <scope>test</scope> </dependency> <dependency> <groupId>org.mongodb</groupId> <artifactId>mongo-java-driver</artifactId> <version>${mongo.version}</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>${maven-surefire-plugin.version}</version> <configuration> <excludes> <exclude>**/*IntegrationTest.java</exclude> <exclude>**/*LongRunningUnitTest.java</exclude> <exclude>**/*ManualTest.java</exclude> </excludes> <testFailureIgnore>true</testFailureIgnore> </configuration> </plugin> </plugins> </build> <profiles> <profile> <id>integration</id> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <executions> <execution> <phase>integration-test</phase> <goals> <goal>test</goal> </goals> <configuration> <excludes> <exclude>**/*ManualTest.java</exclude> </excludes> <includes> <include>**/*IntegrationTest.java</include> </includes> </configuration> </execution> </executions> <configuration> <systemPropertyVariables> <test.mime>json</test.mime> </systemPropertyVariables> </configuration> </plugin> </plugins> </build> </profile> </profiles> <properties> <maven.compiler.source>1.8</maven.compiler.source> <maven.compiler.target>1.8</maven.compiler.target> <junit.version>4.12</junit.version> <mongo.version>3.4.1</mongo.version> <flapdoodle.version>1.11</flapdoodle.version> <maven-surefire-plugin.version>2.19.1</maven-surefire-plugin.version> </properties> </project>