// now, try with another query. If the slots were not released, it should fail with TrafficLimitingSearcher Exception.
// if it failed with "I always fail", it is ok.
Thread searchThread = new Thread() {
public void run() {
try {
searcher.search(null, 0, 1, null, 1, null, null);
} catch (Throwable t) {
assertFalse(t.getMessage().contains("TrafficLimitingSearcher"));
assertTrue(t.getMessage().contains("I always fail"));
semaphorePassed = true;
}