341 lines
14 KiB
XML
341 lines
14 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
<groupId>pl.com.dddbyexamples</groupId>
|
|
<artifactId>shortages-prediction-adapters</artifactId>
|
|
<version>1.0-SNAPSHOT</version>
|
|
|
|
<parent>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-parent</artifactId>
|
|
<version>2.0.2.RELEASE</version>
|
|
<relativePath/>
|
|
</parent>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>pl.com.dddbyexamples</groupId>
|
|
<artifactId>shortages-prediction-model</artifactId>
|
|
<version>1.0-SNAPSHOT</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>pl.com.dddbyexamples</groupId>
|
|
<artifactId>adapter-commons</artifactId>
|
|
<version>1.0-SNAPSHOT</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>pl.com.dddbyexamples</groupId>
|
|
<artifactId>adapter-commons</artifactId>
|
|
<version>1.0-SNAPSHOT</version>
|
|
<type>test-jar</type>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-test</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.spockframework</groupId>
|
|
<artifactId>spock-core</artifactId>
|
|
<version>1.1-groovy-2.4</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.spockframework</groupId>
|
|
<artifactId>spock-spring</artifactId>
|
|
<version>1.1-groovy-2.4</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.cloud</groupId>
|
|
<artifactId>spring-cloud-starter-contract-stub-runner</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.cloud</groupId>
|
|
<artifactId>spring-cloud-starter-contract-verifier</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.restdocs</groupId>
|
|
<artifactId>spring-restdocs-mockmvc</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.h2database</groupId>
|
|
<artifactId>h2</artifactId>
|
|
<version>1.4.197</version>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<dependencyManagement>
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.springframework.cloud</groupId>
|
|
<artifactId>spring-cloud-dependencies</artifactId>
|
|
<version>${spring-cloud.version}</version>
|
|
<type>pom</type>
|
|
<scope>import</scope>
|
|
</dependency>
|
|
</dependencies>
|
|
</dependencyManagement>
|
|
|
|
<properties>
|
|
<java.version>1.8</java.version>
|
|
<spring-cloud.version>Finchley.BUILD-SNAPSHOT</spring-cloud.version>
|
|
<spring-cloud-contract.version>2.0.0.BUILD-SNAPSHOT</spring-cloud-contract.version>
|
|
<!-- [PIPELINE] -->
|
|
<distribution.management.release.id>artifactory-local</distribution.management.release.id>
|
|
<distribution.management.release.url>http://localhost:8081/artifactory/libs-release-local</distribution.management.release.url>
|
|
<distribution.management.snapshot.url>http://localhost:8081/artifactory/libs-snapshot-local</distribution.management.snapshot.url>
|
|
<repo.with.binaries>http://localhost:8081/artifactory/libs-release-local</repo.with.binaries>
|
|
<maven-surefire.version>2.22.0</maven-surefire.version>
|
|
</properties>
|
|
|
|
<!-- [PIPELINE] -->
|
|
<distributionManagement>
|
|
<repository>
|
|
<id>${distribution.management.release.id}</id>
|
|
<name>Release Repository</name>
|
|
<url>${distribution.management.release.url}</url>
|
|
</repository>
|
|
<snapshotRepository>
|
|
<id>${distribution.management.release.id}</id>
|
|
<name>Snapshot Repository</name>
|
|
<url>${distribution.management.snapshot.url}</url>
|
|
</snapshotRepository>
|
|
</distributionManagement>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.codehaus.gmavenplus</groupId>
|
|
<artifactId>gmavenplus-plugin</artifactId>
|
|
<version>1.6</version>
|
|
<executions>
|
|
<execution>
|
|
<goals>
|
|
<goal>addTestSources</goal>
|
|
<goal>compileTests</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-compiler-plugin</artifactId>
|
|
<version>3.7.0</version>
|
|
<configuration>
|
|
<source>1.8</source>
|
|
<target>1.8</target>
|
|
<compilerArgument>-parameters</compilerArgument>
|
|
</configuration>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.codehaus.mojo</groupId>
|
|
<artifactId>build-helper-maven-plugin</artifactId>
|
|
<version>3.0.0</version>
|
|
<executions>
|
|
<execution>
|
|
<id>add-test-source</id>
|
|
<phase>generate-test-sources</phase>
|
|
<goals>
|
|
<goal>add-test-source</goal>
|
|
</goals>
|
|
<configuration>
|
|
<sources>
|
|
<source>${project.build.directory}/generated-test-sources/contracts</source>
|
|
</sources>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
|
|
<profiles>
|
|
<profile>
|
|
<id>default</id>
|
|
<activation>
|
|
<activeByDefault>true</activeByDefault>
|
|
</activation>
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-surefire-plugin</artifactId>
|
|
<version>${maven-surefire.version}</version>
|
|
<configuration>
|
|
<includes>
|
|
<include>**/*Test*.*</include>>
|
|
<include>**/*Spec*.*</include>
|
|
</includes>
|
|
<excludes>
|
|
<exclude>**/smoke/**</exclude>
|
|
<exclude>**/e2e/**</exclude>
|
|
</excludes>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</profile>
|
|
<!-- [PIPELINE] -->
|
|
<profile>
|
|
<id>apicompatibility</id>
|
|
<activation>
|
|
<activeByDefault>false</activeByDefault>
|
|
</activation>
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.codehaus.gmavenplus</groupId>
|
|
<artifactId>gmavenplus-plugin</artifactId>
|
|
<version>1.6</version>
|
|
<executions>
|
|
<execution>
|
|
<goals>
|
|
<goal>addTestSources</goal>
|
|
<goal>compileTests</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
<!-- THIS IS CRITICAL CAUSE BY DEFAULT GMAVEN IGNORES WHATEVER SETUP YOU HAVE -->
|
|
<configuration>
|
|
<testSources>
|
|
<testSource>
|
|
<directory>${project.build.directory}/generated-test-sources/contracts/</directory>
|
|
<includes>
|
|
<include>**/*.groovy</include>
|
|
</includes>
|
|
</testSource>
|
|
<testSource>
|
|
<directory>${project.basedir}/src/test/groovy/</directory>
|
|
<includes>
|
|
<include>**/*.groovy</include>
|
|
</includes>
|
|
</testSource>
|
|
</testSources>
|
|
</configuration>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-surefire-plugin</artifactId>
|
|
<version>${maven-surefire.version}</version>
|
|
<configuration>
|
|
<includes>
|
|
<include>contracttests/**/*Test*.*</include>
|
|
<include>contracttests/**/*Spec*.*</include>
|
|
</includes>
|
|
<failIfNoTests>true</failIfNoTests>
|
|
</configuration>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.springframework.cloud</groupId>
|
|
<artifactId>spring-cloud-contract-maven-plugin</artifactId>
|
|
<version>${spring-cloud-contract.version}</version>
|
|
<extensions>true</extensions>
|
|
<configuration>
|
|
<!-- Will be injected by the pipeline -->
|
|
<contractsRepositoryUrl>${repo.with.binaries}</contractsRepositoryUrl>
|
|
<contractsMode>REMOTE</contractsMode>
|
|
<!--<contractsMode>LOCAL</contractsMode>-->
|
|
<!--<deleteStubsAfterTest>false</deleteStubsAfterTest>-->
|
|
<contractDependency>
|
|
<groupId>${project.groupId}</groupId>
|
|
<artifactId>app-monolith</artifactId>
|
|
<classifier>stubs</classifier>
|
|
<version>${latest.production.version}</version>
|
|
</contractDependency>
|
|
<testFramework>SPOCK</testFramework>
|
|
<testMode>EXPLICIT</testMode>
|
|
<baseClassForTests>io.dddbyexamples.factory.shortages.prediction.monitoring.persistence.BaseClass</baseClassForTests>
|
|
<basePackageForTests>io.dddbyexamples.contracttests</basePackageForTests>
|
|
<contractsPath>META-INF/${project.groupId}/app-monolith/${latest.production.version}/shortages-prediction-adapters/contracts</contractsPath>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</profile>
|
|
<!-- [PIPELINE] -->
|
|
<profile>
|
|
<id>smoke</id>
|
|
<activation>
|
|
<activeByDefault>false</activeByDefault>
|
|
</activation>
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-surefire-plugin</artifactId>
|
|
<version>${maven-surefire.version}</version>
|
|
<configuration>
|
|
<includes>
|
|
<include>smoke/**/*Tests.java</include>
|
|
<include>smoke/**/*Test.java</include>
|
|
<include>smoke/**/*Spec.*</include>
|
|
</includes>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</profile>
|
|
<!-- [PIPELINE] -->
|
|
<profile>
|
|
<id>e2e</id>
|
|
<activation>
|
|
<activeByDefault>false</activeByDefault>
|
|
</activation>
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-surefire-plugin</artifactId>
|
|
<version>${maven-surefire.version}</version>
|
|
<configuration>
|
|
<includes>
|
|
<include>e2e/**/*Tests.java</include>
|
|
<include>e2e/**/*Test.java</include>
|
|
<include>e2e/**/*Spec.*</include>
|
|
</includes>
|
|
</configuration>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</profile>
|
|
</profiles>
|
|
|
|
<repositories>
|
|
<repository>
|
|
<id>spring-snapshots</id>
|
|
<name>Spring Snapshots</name>
|
|
<url>https://repo.spring.io/libs-snapshot</url>
|
|
<snapshots>
|
|
<enabled>true</enabled>
|
|
</snapshots>
|
|
<releases>
|
|
<enabled>true</enabled>
|
|
</releases>
|
|
</repository>
|
|
</repositories>
|
|
<pluginRepositories>
|
|
<pluginRepository>
|
|
<id>spring-snapshots</id>
|
|
<name>Spring Snapshots</name>
|
|
<url>https://repo.spring.io/libs-snapshot</url>
|
|
<snapshots>
|
|
<enabled>true</enabled>
|
|
</snapshots>
|
|
<releases>
|
|
<enabled>true</enabled>
|
|
</releases>
|
|
</pluginRepository>
|
|
</pluginRepositories>
|
|
|
|
</project>
|