/** * Initializes the Solr connection and tests the connection through a ping. * */ protected function initializeSearch() { $solrConnection = GeneralUtility::makeInstance('ApacheSolrForTypo3\\Solr\\ConnectionManager')->getConnectionByPageId($GLOBALS['TSFE']->id, $GLOBALS['TSFE']->sys_language_uid, $GLOBALS['TSFE']->MP); $search = GeneralUtility::makeInstance('ApacheSolrForTypo3\\Solr\\Search', $solrConnection); /** @var $this->searchService ApacheSolrForTypo3\Solr\Domain\Search\ResultSet\SearchResultSetService */ $this->searchResultsSetService = GeneralUtility::makeInstance('ApacheSolrForTypo3\\Solr\\Domain\\Search\\ResultSet\\SearchResultSetService', $this->typoScriptConfiguration, $search, $this); $this->solrAvailable = $this->searchResultsSetService->getIsSolrAvailable(); $this->search = $this->searchResultsSetService->getSearch(); }
/** * @return void */ private function assertPerPageInSessionWillNotBeChanged() { $this->searchResultSetService->expects($this->never())->method('setPerPageInSession'); }