Apache Lucene open-source search software
fix testOldStyleDefaults so that it actually tests the old style defaults -- i broke it with a typo way back in r441175
Chris M. Hostetterd16fe2eccad2
diff --git a/src/test/org/apache/solr/DisMaxRequestHandlerTest.java b/src/test/org/apache/solr/DisMaxRequestHandlerTest.javaindex a0f63758add..adc79bc6775 100644--- a/src/test/org/apache/solr/DisMaxRequestHandlerTest.java+++ b/src/test/org/apache/solr/DisMaxRequestHandlerTest.java@@ -70,6 +70,9 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {}public void testSomeStuff() throws Exception {+ doTestSomeStuff("dismax");+ }+ public void doTestSomeStuff(final String qt) throws Exception {populate();assertQ("basic match",@@ -91,7 +94,7 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {assertQ("multi qf",req("q", "cool"- ,"qt", "dismax"+ ,"qt", qt,"version", "2.0","qf", "subject","qf", "features_t"@@ -101,7 +104,7 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {assertQ("boost query",req("q", "cool stuff"- ,"qt", "dismax"+ ,"qt", qt,"version", "2.0","bq", "subject:hell^400")@@ -113,7 +116,7 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {assertQ("multi boost query",req("q", "cool stuff"- ,"qt", "dismax"+ ,"qt", qt,"version", "2.0","bq", "subject:hell^400","bq", "subject:cool^4"@@ -138,14 +141,14 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {);assertQ("relying on ALTQ from config",- req( "qt", "dismax",+ req( "qt", qt,"fq", "id:666","facet", "false" ),"//*[@numFound='1']");assertQ("explicit ALTQ",- req( "qt", "dismax",+ req( "qt", qt,"q.alt", "id:9999","fq", "id:666","facet", "false" )@@ -153,12 +156,12 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {);assertQ("no query slop == no match",- req( "qt", "dismax",+ req( "qt", qt,"q", "\"cool chick\"" ),"//*[@numFound='0']");assertQ("query slop == match",- req( "qt", "dismax",+ req( "qt", qt,"qs", "2","q", "\"cool chick\"" ),"//*[@numFound='1']"@@ -195,12 +198,12 @@ public class DisMaxRequestHandlerTest extends AbstractSolrTestCase {public void testOldStyleDefaults() throws Exception {lrf = h.getRequestFactory- ("dismax", 0, 20,+ ("dismaxOldStyleDefaults", 0, 20,"version","2.0","facet", "true","facet.field","t_s");- testSomeStuff();+ doTestSomeStuff("dismaxOldStyleDefaults");}