From fc4ed67dc2dbc29c8bc8d9c57340a04dece47357 Mon Sep 17 00:00:00 2001 From: Mark Robert Miller Date: Wed, 2 Jan 2013 01:19:08 +0000 Subject: [PATCH] tests: fix - only do this check if there are actually different docs git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1427616 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/solr/cloud/AbstractFullDistribZkTestBase.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/solr/test-framework/src/java/org/apache/solr/cloud/AbstractFullDistribZkTestBase.java b/solr/test-framework/src/java/org/apache/solr/cloud/AbstractFullDistribZkTestBase.java index 036bc7d61d0..2f82670d089 100644 --- a/solr/test-framework/src/java/org/apache/solr/cloud/AbstractFullDistribZkTestBase.java +++ b/solr/test-framework/src/java/org/apache/solr/cloud/AbstractFullDistribZkTestBase.java @@ -1018,13 +1018,15 @@ public abstract class AbstractFullDistribZkTestBase extends AbstractDistribZkTes Set differences = showDiff(controlDocList, cloudDocList,"controlDocList","cloudDocList"); // get versions for the mismatched ids + boolean foundId = false; StringBuilder ids = new StringBuilder("id:("); for (Map doc : differences) { ids.append(" "+doc.get("id")); + foundId = true; } ids.append(")"); - if (ids.length() > 0) { + if (foundId) { // get versions for those ids that don't match q = params("q", ids.toString(), "rows", "100000", "fl", "id,_version_", "sort", "id asc", "tests",