Commit 01b23c88 authored by Stephane Nicoll's avatar Stephane Nicoll

Use random port for Cassandra tests

Closes gh-4028
parent 033823f4
...@@ -35,12 +35,40 @@ ...@@ -35,12 +35,40 @@
<dependency> <dependency>
<groupId>org.cassandraunit</groupId> <groupId>org.cassandraunit</groupId>
<artifactId>cassandra-unit-spring</artifactId> <artifactId>cassandra-unit-spring</artifactId>
<version>2.1.3.1</version> <version>2.1.9.2</version>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
</dependencies> </dependencies>
<build> <build>
<plugins> <plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>reserve-cassandra-port</id>
<goals>
<goal>reserve-network-port</goal>
</goals>
<phase>process-resources</phase>
<configuration>
<portNames>
<portName>cassandra.port</portName>
</portNames>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<systemPropertyVariables>
<spring.data.cassandra.port>${cassandra.port}</spring.data.cassandra.port>
<cassandra.native_transport_port>${cassandra.port}</cassandra.native_transport_port>
</systemPropertyVariables>
</configuration>
</plugin>
<plugin> <plugin>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId> <artifactId>spring-boot-maven-plugin</artifactId>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment