Fix occasional test failure due to a missing trigger config.

This commit is contained in:
Andrzej Bialecki 2018-09-19 11:57:39 +02:00
parent c696cafc0d
commit 408232635a
1 changed files with 4 additions and 1 deletions

View File

@ -127,7 +127,10 @@ public class TestSimTriggerIntegration extends SimSolrCloudTestCase {
SolrRequest req = createAutoScalingRequest(SolrRequest.METHOD.POST, suspendTriggerCommand); SolrRequest req = createAutoScalingRequest(SolrRequest.METHOD.POST, suspendTriggerCommand);
SolrClient solrClient = cluster.simGetSolrClient(); SolrClient solrClient = cluster.simGetSolrClient();
NamedList<Object> response = solrClient.request(req); NamedList<Object> response = solrClient.request(req);
assertEquals(response.get("result").toString(), "success"); String result = response.get("result").toString();
if (!"success".equals(result) && !result.contains("No trigger exists")) {
fail("Unexpected response: " + result);
}
waitForSeconds = 1 + random().nextInt(3); waitForSeconds = 1 + random().nextInt(3);
actionConstructorCalled = new CountDownLatch(1); actionConstructorCalled = new CountDownLatch(1);