private function SolrBaseQueryTests::_apachesolr_drupal_query in Apache Solr Search 7
Same name and namespace in other branches
- 8 tests/solr_base_query.test \SolrBaseQueryTests::_apachesolr_drupal_query()
 - 6.3 tests/solr_base_query.test \SolrBaseQueryTests::_apachesolr_drupal_query()
 
Helper function to simulate the auto loading and other non-needed functions that otherwise require a database
Return value
See also
2 calls to SolrBaseQueryTests::_apachesolr_drupal_query()
- SolrBaseQueryTests::testAddParams in tests/
solr_base_query.test  - SolrBaseQueryTests::testParseFilters in tests/
solr_base_query.test  - Test ordering of parsed filter positions.
 
File
- tests/
solr_base_query.test, line 30  
Class
- SolrBaseQueryTests
 - Unit tests for query object methods.
 
Code
private function _apachesolr_drupal_query($name, $params = array(), $solrsort = '', $base_path = '', $solr = NULL) {
  if (empty($solr)) {
    $solr = new DummySolr(NULL);
  }
  return new SolrBaseQuery($name, $solr, $params, $solrsort, $base_path);
}