eZ\Publish\Core\Search\Legacy\Tests\Content\HandlerContentTest::getContentSearchHandler PHP Method

getContentSearchHandler() protected method

This method returns a fully functional search handler to perform tests on.
protected getContentSearchHandler ( array $fullTextSearchConfiguration = [] ) : Handler
$fullTextSearchConfiguration array
return eZ\Publish\Core\Search\Legacy\Content\Handler
    protected function getContentSearchHandler(array $fullTextSearchConfiguration = array())
    {
        $transformationProcessor = new Persistence\TransformationProcessor\DefinitionBased(new Persistence\TransformationProcessor\DefinitionBased\Parser(), new Persistence\TransformationProcessor\PcreCompiler(new Persistence\Utf8Converter()), glob(__DIR__ . '/../../../../Persistence/Tests/TransformationProcessor/_fixtures/transformations/*.tr'));
        $commaSeparatedCollectionValueHandler = new Content\Common\Gateway\CriterionHandler\FieldValue\Handler\Collection($this->getDatabaseHandler(), $transformationProcessor, ',');
        $hyphenSeparatedCollectionValueHandler = new Content\Common\Gateway\CriterionHandler\FieldValue\Handler\Collection($this->getDatabaseHandler(), $transformationProcessor, '-');
        $simpleValueHandler = new Content\Common\Gateway\CriterionHandler\FieldValue\Handler\Simple($this->getDatabaseHandler(), $transformationProcessor);
        $compositeValueHandler = new Content\Common\Gateway\CriterionHandler\FieldValue\Handler\Composite($this->getDatabaseHandler(), $transformationProcessor);
        return new Content\Handler(new Content\Gateway\DoctrineDatabase($this->getDatabaseHandler(), new Content\Common\Gateway\CriteriaConverter(array(new Content\Common\Gateway\CriterionHandler\ContentId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\LogicalNot($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\LogicalAnd($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\LogicalOr($this->getDatabaseHandler()), new Content\Gateway\CriterionHandler\Subtree($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\ContentTypeId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\ContentTypeIdentifier($this->getDatabaseHandler(), $this->getContentTypeHandler()), new Content\Common\Gateway\CriterionHandler\ContentTypeGroupId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\DateMetadata($this->getDatabaseHandler()), new Content\Gateway\CriterionHandler\LocationId($this->getDatabaseHandler()), new Content\Gateway\CriterionHandler\ParentLocationId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\RemoteId($this->getDatabaseHandler()), new Content\Gateway\CriterionHandler\LocationRemoteId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\SectionId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\FullText($this->getDatabaseHandler(), $transformationProcessor, $fullTextSearchConfiguration), new Content\Common\Gateway\CriterionHandler\Field($this->getDatabaseHandler(), $this->getContentTypeHandler(), $this->getLanguageHandler(), $this->getConverterRegistry(), new Content\Common\Gateway\CriterionHandler\FieldValue\Converter(new Content\Common\Gateway\CriterionHandler\FieldValue\HandlerRegistry(array('ezboolean' => $simpleValueHandler, 'ezcountry' => $commaSeparatedCollectionValueHandler, 'ezdate' => $simpleValueHandler, 'ezdatetime' => $simpleValueHandler, 'ezemail' => $simpleValueHandler, 'ezinteger' => $simpleValueHandler, 'ezobjectrelation' => $simpleValueHandler, 'ezobjectrelationlist' => $commaSeparatedCollectionValueHandler, 'ezselection' => $hyphenSeparatedCollectionValueHandler, 'eztime' => $simpleValueHandler)), $compositeValueHandler), $transformationProcessor), new Content\Common\Gateway\CriterionHandler\ObjectStateId($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\LanguageCode($this->getDatabaseHandler(), $this->getLanguageMaskGenerator()), new Content\Gateway\CriterionHandler\Visibility($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\MatchAll($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\UserMetadata($this->getDatabaseHandler()), new Content\Common\Gateway\CriterionHandler\FieldRelation($this->getDatabaseHandler(), $this->getContentTypeHandler(), $this->getLanguageHandler()))), new Content\Common\Gateway\SortClauseConverter(array(new Content\Common\Gateway\SortClauseHandler\ContentId($this->getDatabaseHandler()))), $this->getLanguageHandler()), $this->getMock('eZ\\Publish\\Core\\Search\\Legacy\\Content\\Location\\Gateway'), new Content\WordIndexer\Gateway\DoctrineDatabase($this->getDatabaseHandler(), $this->getContentTypeHandler(), $this->getDefinitionBasedTransformationProcessor(), new Content\WordIndexer\Repository\SearchIndex($this->getDatabaseHandler()), $this->getFullTextSearchConfiguration()), $this->getContentMapperMock(), $this->getMock('eZ\\Publish\\Core\\Persistence\\Legacy\\Content\\Location\\Mapper'), $this->getLanguageHandler(), $this->getFullTextMapper($this->getContentTypeHandler()));
    }
HandlerContentTest