tests: prevent expected commit exceptions from failing test

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@927837 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Yonik Seeley 2010-03-26 13:21:06 +00:00
parent f8c0344ccf
commit 256789a4ff
1 changed files with 6 additions and 0 deletions

View File

@ -105,10 +105,16 @@ public abstract class LargeVolumeTestBase extends SolrJettyTestBase
}
resp = tserver.add(docs);
assertEquals(0, resp.getStatus());
try {
resp = tserver.commit();
assertEquals(0, resp.getStatus());
resp = tserver.optimize();
assertEquals(0, resp.getStatus());
} catch (Exception e) {
// a commit/optimize can fail with a too many warming searchers exception
log.info("Caught benign exception during commit: " + e.getMessage());
}
} catch (Exception e) {
e.printStackTrace();