lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From no...@apache.org
Subject lucene-solr:master: SOLR-11380: Test failure
Date Thu, 02 Nov 2017 08:53:13 GMT
Repository: lucene-solr
Updated Branches:
  refs/heads/master bf040a88e -> f564f9ca4


SOLR-11380: Test failure


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

Branch: refs/heads/master
Commit: f564f9ca4b7766d1bcad18f2f18f8b64929cdef2
Parents: bf040a8
Author: Noble Paul <noble@apache.org>
Authored: Thu Nov 2 19:21:29 2017 +1030
Committer: Noble Paul <noble@apache.org>
Committed: Thu Nov 2 19:22:57 2017 +1030

----------------------------------------------------------------------
 .../apache/solr/client/solrj/request/TestV1toV2ApiMapper.java  | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/f564f9ca/solr/solrj/src/test/org/apache/solr/client/solrj/request/TestV1toV2ApiMapper.java
----------------------------------------------------------------------
diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/request/TestV1toV2ApiMapper.java
b/solr/solrj/src/test/org/apache/solr/client/solrj/request/TestV1toV2ApiMapper.java
index 7daefb9..9573b3b 100644
--- a/solr/solrj/src/test/org/apache/solr/client/solrj/request/TestV1toV2ApiMapper.java
+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/request/TestV1toV2ApiMapper.java
@@ -22,7 +22,9 @@ import java.util.Map;
 
 import com.google.common.collect.ImmutableMap;
 import org.apache.lucene.util.LuceneTestCase;
+import org.apache.solr.client.solrj.impl.BinaryRequestWriter;
 import org.apache.solr.client.solrj.request.CollectionAdminRequest.Create;
+import org.apache.solr.common.util.ContentStreamBase;
 import org.apache.solr.common.util.Utils;
 
 public class TestV1toV2ApiMapper extends LuceneTestCase {
@@ -35,7 +37,7 @@ public class TestV1toV2ApiMapper extends LuceneTestCase {
             .put("p2","v2")
             .build());
     V2Request v2r = V1toV2ApiMapper.convert(cmd).build();
-    Map m = (Map) Utils.fromJSON(v2r.getContentStreams().iterator().next().getStream());
+    Map m = (Map) Utils.fromJSON(ContentStreamBase.create(new BinaryRequestWriter(), v2r).getStream());
     assertEquals("/c", v2r.getPath());
     assertEquals("v1", Utils.getObjectByPath(m,true,"/create/properties/p1"));
     assertEquals("v2", Utils.getObjectByPath(m,true,"/create/properties/p2"));
@@ -44,7 +46,7 @@ public class TestV1toV2ApiMapper extends LuceneTestCase {
 
     CollectionAdminRequest.AddReplica addReplica = CollectionAdminRequest.addReplicaToShard("mycoll",
"shard1");
     v2r = V1toV2ApiMapper.convert(addReplica).build();
-    m = (Map) Utils.fromJSON(v2r.getContentStreams().iterator().next().getStream());
+    m = (Map) Utils.fromJSON(ContentStreamBase.create(new BinaryRequestWriter(), v2r).getStream());
     assertEquals("/c/mycoll/shards", v2r.getPath());
     assertEquals("shard1", Utils.getObjectByPath(m,true,"/add-replica/shard"));
     assertEquals("NRT", Utils.getObjectByPath(m,true,"/add-replica/type"));


Mime
View raw message