lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dsmi...@apache.org
Subject lucene-solr:master: SOLR-5750: Fix test to specify the collection on add
Date Thu, 05 May 2016 13:43:11 GMT
Repository: lucene-solr
Updated Branches:
  refs/heads/master 382ffdb63 -> 18d933ee6


SOLR-5750: Fix test to specify the collection on add


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/18d933ee
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/18d933ee
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/18d933ee

Branch: refs/heads/master
Commit: 18d933ee65320ab1cae92a79d6635996fee9e818
Parents: 382ffdb
Author: David Smiley <dsmiley@apache.org>
Authored: Thu May 5 09:41:47 2016 -0400
Committer: David Smiley <dsmiley@apache.org>
Committed: Thu May 5 09:41:47 2016 -0400

----------------------------------------------------------------------
 .../src/test/org/apache/solr/cloud/TestCloudBackupRestore.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/18d933ee/solr/core/src/test/org/apache/solr/cloud/TestCloudBackupRestore.java
----------------------------------------------------------------------
diff --git a/solr/core/src/test/org/apache/solr/cloud/TestCloudBackupRestore.java b/solr/core/src/test/org/apache/solr/cloud/TestCloudBackupRestore.java
index 2dba20b..5e35616 100644
--- a/solr/core/src/test/org/apache/solr/cloud/TestCloudBackupRestore.java
+++ b/solr/core/src/test/org/apache/solr/cloud/TestCloudBackupRestore.java
@@ -121,7 +121,6 @@ public class TestCloudBackupRestore extends SolrCloudTestCase {
       log.info("Indexing ZERO test docs");
       return;
     }
-    CloudSolrClient client = cluster.getSolrClient();
     List<SolrInputDocument> docs = new ArrayList<>(numDocs);
     for (int i=0; i<numDocs; i++) {
       SolrInputDocument doc = new SolrInputDocument();
@@ -129,7 +128,8 @@ public class TestCloudBackupRestore extends SolrCloudTestCase {
       doc.addField("shard_s", "shard" + (1 + random.nextInt(NUM_SHARDS))); // for implicit
router
       docs.add(doc);
     }
-    client.add(docs);// batch
+    CloudSolrClient client = cluster.getSolrClient();
+    client.add(collectionName, docs);// batch
     client.commit(collectionName);
   }
 


Mime
View raw message