Github user andyetitmoves commented on a diff in the pull request:
https://github.com/apache/lucene-solr/pull/121#discussion_r22386755
--- Diff:
solr/test-framework/src/java/org/apache/solr/BaseDistributedSearchTestCase.java
---
@@ -861,23 +877,107 @@ protected void compareResponses(QueryResponse a,
QueryResponse b) {
compareSolrResponses(a, b);
}
- @Test
- public void testDistribSearch() throws Exception {
- if (fixShardCount) {
- createServers(shardCount);
- RandVal.uniqueValues = new HashSet(); //reset random values
- doTest();
- destroyServers();
- } else {
- for (int nServers = 1; nServers < shardCount; nServers++) {
- createServers(nServers);
+ @Retention(RetentionPolicy.RUNTIME)
+ @Target(ElementType.METHOD)
+ public @interface ShardsRepeat {
+ public abstract int min() default 1;
+ public abstract int max() default DEFAULT_MAX_SHARD_COUNT;
+ }
+
+ @Retention(RetentionPolicy.RUNTIME)
+ @Target(ElementType.METHOD)
+ public @interface ShardsFixed {
+ public abstract int num();
+ }
+
+ public class ShardsRepeatRule implements TestRule {
+
+ private abstract class ShardsStatement extends Statement {
+ abstract protected void callStatement() throws Throwable;
+
+ @Override
+ public void evaluate() throws Throwable {
+ distribSetUp();
--- End diff --
No, {{distribSetUp}} is actually optional, quite a few sub-classes don't
call it..
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]