PHP Class eZ\Publish\Core\Search\Tests\FieldNameResolverTest

Inheritance: extends eZ\Publish\Core\Search\Tests\TestCase
Show file Open project: ezsystems/ezpublish-kernel

Protected Properties

Property Type Description
$contentTypeHandlerMock eZ\Publish\SPI\Persistence\Content\Type\Handler | PHPUnit_Framework_MockObject_MockObject
$fieldNameGeneratorMock eZ\Publish\Core\Search\Common\FieldNameGenerator | PHPUnit_Framework_MockObject_MockObject
$fieldRegistryMock eZ\Publish\Core\Search\Common\FieldRegistry | PHPUnit_Framework_MockObject_MockObject

Public Methods

Method Description
testGetFieldNames ( )
testGetFieldNamesReturnsEmptyArray ( )
testGetFieldNamesWithNamedField ( )
testGetFieldNamesWithTypedAndNamedField ( )
testGetFieldNamesWithTypedField ( )
testGetIndexFieldNameCustomField ( )
testGetIndexFieldNameDefaultMatchField ( )
testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException ( )
testGetIndexFieldNameDefaultSortField ( )
testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException ( )
testGetIndexFieldNameNamedField ( )
testGetIndexFieldNameNamedFieldThrowsRuntimeException ( )
testGetSortFieldName ( )
testGetSortFieldNameReturnsNull ( )

Protected Methods

Method Description
getContentTypeHandlerMock ( ) : eZ\Publish\SPI\Persistence\Content\Type\Handler | PHPUnit_Framework_MockObject_MockObject
getCriterionMock ( ) : eZ\Publish\API\Repository\Values\Content\Query\Criterion | PHPUnit_Framework_MockObject_MockObject
getFieldNameGeneratorMock ( ) : FieldNameGenerator | PHPUnit_Framework_MockObject_MockObject
getFieldRegistryMock ( ) : FieldRegistry | PHPUnit_Framework_MockObject_MockObject
getIndexFieldTypeMock ( ) : eZ\Publish\SPI\FieldType\Indexable | PHPUnit_Framework_MockObject_MockObject
getMockedFieldNameResolver ( array $methods = [] ) : FieldNameResolver | PHPUnit_Framework_MockObject_MockObject
getSearchFieldTypeMock ( ) : eZ\Publish\SPI\Search\FieldType | PHPUnit_Framework_MockObject_MockObject
getSortClauseMock ( ) : eZ\Publish\API\Repository\Values\Content\Query\SortClause | PHPUnit_Framework_MockObject_MockObject

Method Details

getContentTypeHandlerMock() protected method

protected getContentTypeHandlerMock ( ) : eZ\Publish\SPI\Persistence\Content\Type\Handler | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\SPI\Persistence\Content\Type\Handler | PHPUnit_Framework_MockObject_MockObject

getCriterionMock() protected method

protected getCriterionMock ( ) : eZ\Publish\API\Repository\Values\Content\Query\Criterion | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\API\Repository\Values\Content\Query\Criterion | PHPUnit_Framework_MockObject_MockObject

getFieldNameGeneratorMock() protected method

protected getFieldNameGeneratorMock ( ) : FieldNameGenerator | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\Core\Search\Common\FieldNameGenerator | PHPUnit_Framework_MockObject_MockObject

getFieldRegistryMock() protected method

protected getFieldRegistryMock ( ) : FieldRegistry | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\Core\Search\Common\FieldRegistry | PHPUnit_Framework_MockObject_MockObject

getIndexFieldTypeMock() protected method

protected getIndexFieldTypeMock ( ) : eZ\Publish\SPI\FieldType\Indexable | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\SPI\FieldType\Indexable | PHPUnit_Framework_MockObject_MockObject

getMockedFieldNameResolver() protected method

protected getMockedFieldNameResolver ( array $methods = [] ) : FieldNameResolver | PHPUnit_Framework_MockObject_MockObject
$methods array
return eZ\Publish\Core\Search\Common\FieldNameResolver | PHPUnit_Framework_MockObject_MockObject

getSearchFieldTypeMock() protected method

protected getSearchFieldTypeMock ( ) : eZ\Publish\SPI\Search\FieldType | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\SPI\Search\FieldType | PHPUnit_Framework_MockObject_MockObject

getSortClauseMock() protected method

protected getSortClauseMock ( ) : eZ\Publish\API\Repository\Values\Content\Query\SortClause | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\API\Repository\Values\Content\Query\SortClause | PHPUnit_Framework_MockObject_MockObject

testGetFieldNames() public method

public testGetFieldNames ( )

testGetFieldNamesReturnsEmptyArray() public method

testGetFieldNamesWithNamedField() public method

testGetFieldNamesWithTypedAndNamedField() public method

testGetFieldNamesWithTypedField() public method

testGetIndexFieldNameCustomField() public method

testGetIndexFieldNameDefaultMatchField() public method

testGetIndexFieldNameDefaultMatchFieldThrowsRuntimeException() public method

testGetIndexFieldNameDefaultSortField() public method

testGetIndexFieldNameDefaultSortFieldThrowsRuntimeException() public method

testGetIndexFieldNameNamedField() public method

testGetIndexFieldNameNamedFieldThrowsRuntimeException() public method

testGetSortFieldName() public method

testGetSortFieldNameReturnsNull() public method

Property Details

$contentTypeHandlerMock protected property

protected Handler,eZ\Publish\SPI\Persistence\Content\Type|PHPUnit_Framework_MockObject_MockObject $contentTypeHandlerMock
return eZ\Publish\SPI\Persistence\Content\Type\Handler | PHPUnit_Framework_MockObject_MockObject

$fieldNameGeneratorMock protected property

protected FieldNameGenerator,eZ\Publish\Core\Search\Common|PHPUnit_Framework_MockObject_MockObject $fieldNameGeneratorMock
return eZ\Publish\Core\Search\Common\FieldNameGenerator | PHPUnit_Framework_MockObject_MockObject

$fieldRegistryMock protected property

protected FieldRegistry,eZ\Publish\Core\Search\Common|PHPUnit_Framework_MockObject_MockObject $fieldRegistryMock
return eZ\Publish\Core\Search\Common\FieldRegistry | PHPUnit_Framework_MockObject_MockObject