diff --git a/.travis.yml b/.travis.yml index 0e651dc58a..fd3e646ae0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,13 +3,28 @@ language: java jdk: - oraclejdk8 -services: - - mongodb +before_script: + - mongod --version env: matrix: - PROFILE=ci - PROFILE=mongo-next + - PROFILE=mongo3 + - PROFILE=mongo3-next + - PROFILE=mongo31 + - PROFILE=mongo32 + - PROFILE=mongo33-next + +# Current MongoDB version is 2.4.2 as of 2016-04, see https://github.com/travis-ci/travis-ci/issues/3694 +# apt-get starts a MongoDB instance so it's not started using before_script +addons: + apt: + sources: + - mongodb-3.2-precise + packages: + - mongodb-org-server + - mongodb-org-shell sudo: false diff --git a/pom.xml b/pom.xml index 165903c30b..4a37c488ad 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ org.springframework.data spring-data-mongodb-parent - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT pom Spring Data MongoDB @@ -107,7 +107,7 @@ mongo-next - 2.14.0-SNAPSHOT + 2.15.0-SNAPSHOT @@ -148,16 +148,25 @@ mongo31 - 3.1.0 + 3.1.1 - mongo32-next + mongo32 - 3.2.0-SNAPSHOT + 3.2.2 + + + + + + + mongo33-next + + 3.3.0-SNAPSHOT diff --git a/spring-data-mongodb-cross-store/pom.xml b/spring-data-mongodb-cross-store/pom.xml index 6554045e11..03c487316c 100644 --- a/spring-data-mongodb-cross-store/pom.xml +++ b/spring-data-mongodb-cross-store/pom.xml @@ -6,7 +6,7 @@ org.springframework.data spring-data-mongodb-parent - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT ../pom.xml @@ -48,7 +48,7 @@ org.springframework.data spring-data-mongodb - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT diff --git a/spring-data-mongodb-distribution/pom.xml b/spring-data-mongodb-distribution/pom.xml index 2d02722262..7006438c86 100644 --- a/spring-data-mongodb-distribution/pom.xml +++ b/spring-data-mongodb-distribution/pom.xml @@ -13,7 +13,7 @@ org.springframework.data spring-data-mongodb-parent - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT ../pom.xml diff --git a/spring-data-mongodb-log4j/pom.xml b/spring-data-mongodb-log4j/pom.xml index ee5e3336db..d357ed999c 100644 --- a/spring-data-mongodb-log4j/pom.xml +++ b/spring-data-mongodb-log4j/pom.xml @@ -5,7 +5,7 @@ org.springframework.data spring-data-mongodb-parent - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT ../pom.xml diff --git a/spring-data-mongodb/pom.xml b/spring-data-mongodb/pom.xml index edfa519fad..f22cef8ee1 100644 --- a/spring-data-mongodb/pom.xml +++ b/spring-data-mongodb/pom.xml @@ -11,7 +11,7 @@ org.springframework.data spring-data-mongodb-parent - 1.10.0.BUILD-SNAPSHOT + 1.10.0.DATAMONGO-1411-SNAPSHOT ../pom.xml diff --git a/spring-data-mongodb/src/test/java/org/springframework/data/mongodb/config/MongoNamespaceReplicaSetTests.java b/spring-data-mongodb/src/test/java/org/springframework/data/mongodb/config/MongoNamespaceReplicaSetTests.java index f3e15aec48..f76e768930 100644 --- a/spring-data-mongodb/src/test/java/org/springframework/data/mongodb/config/MongoNamespaceReplicaSetTests.java +++ b/spring-data-mongodb/src/test/java/org/springframework/data/mongodb/config/MongoNamespaceReplicaSetTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2011-2012 the original author or authors. + * Copyright 2011-2016 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -20,6 +20,7 @@ import static org.junit.Assert.*; import java.net.InetAddress; +import java.util.ArrayList; import java.util.List; import org.junit.Ignore; @@ -37,6 +38,13 @@ import com.mongodb.Mongo; import com.mongodb.ServerAddress; +/** + * + * @author Mark Pollack + * @author Oliver Gierke + * @author Thomas Darimont + * @author Mark Paluch + */ @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration public class MongoNamespaceReplicaSetTests { @@ -70,10 +78,13 @@ public void testParsingWithPropertyPlaceHolder() throws Exception { assertThat(replicaSetSeeds, is(notNullValue())); assertThat(replicaSetSeeds, hasSize(3)); - assertThat( - replicaSetSeeds, - hasItems(new ServerAddress("192.168.174.130", 27017), new ServerAddress("192.168.174.130", 27018), - new ServerAddress("192.168.174.130", 27019))); + + List ports = new ArrayList(); + for (ServerAddress replicaSetSeed : replicaSetSeeds) { + ports.add(replicaSetSeed.getPort()); + } + + assertThat(ports, hasItems(27017, 27018, 27019)); } @Test