Skip to content

Commit

Permalink
[TEST] Fail test if dummy doc is not found
Browse files Browse the repository at this point in the history
Reverts back 7d3da91 after fix in #15900

Closes #8706
  • Loading branch information
Yannick Welsch committed Feb 2, 2016
1 parent c7a818d commit cf28d62
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1435,11 +1435,8 @@ public void indexRandom(boolean forceRefresh, boolean dummyDocuments, boolean ma
if (!bogusIds.isEmpty()) {
// delete the bogus types again - it might trigger merges or at least holes in the segments and enforces deleted docs!
for (Tuple<String, String> doc : bogusIds) {
// see https://github.com/elasticsearch/elasticsearch/issues/8706
final DeleteResponse deleteResponse = client().prepareDelete(doc.v1(), RANDOM_BOGUS_TYPE, doc.v2()).get();
if (deleteResponse.isFound() == false) {
logger.warn("failed to delete a dummy doc [{}][{}]", doc.v1(), doc.v2());
}
assertTrue("failed to delete a dummy doc [" + doc.v1() + "][" + doc.v2() + "]",
client().prepareDelete(doc.v1(), RANDOM_BOGUS_TYPE, doc.v2()).get().isFound());
}
}
if (forceRefresh) {
Expand Down

0 comments on commit cf28d62

Please sign in to comment.