PHP Class eZ\Publish\Core\REST\Common\Tests\Output\ValueObjectVisitorBaseTest

Inheritance: extends eZ\Publish\Core\REST\Server\Tests\BaseTest, use trait eZ\Publish\Core\REST\Common\Tests\AssertXmlTagTrait
Datei anzeigen Open project: ezsystems/ezpublish-kernel

Protected Properties

Property Type Description
$generator eZ\Publish\Core\REST\Common\Output\Generator\Xml Output generator.
$requestParser eZ\Publish\Core\REST\Common\RequestParser
$visitorMock eZ\Publish\Core\REST\Common\Output\Visitor Visitor mock.

Protected Methods

Method Description
addRouteExpectation ( string $routeName, array $arguments, string $returnValue ) Adds an expectation to the routerMock. Expectations must be added sequentially.
addTemplatedRouteExpectation ( string $routeName, array $arguments, string $returnValue ) Adds an expectation to the templatedRouterMock. Expectations must be added sequentially.
assertXPath ( DOMNode $domNode, string $xpathExpression ) Asserts that the given $xpathExpression returns a non empty node set with $domNode as its context.
getGenerator ( ) : Xml Gets the output generator.
getRequestParser ( ) : eZ\Publish\Core\REST\Common\RequestParser | PHPUnit_Framework_MockObject_MockObject
getResponseMock ( ) : Response | PHPUnit_Framework_MockObject_MockObject
getRouterMock ( ) : Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject
getTemplatedRouterMock ( ) : Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject
getVisitor ( )
getVisitorMock ( ) : Visitor | PHPUnit_Framework_MockObject_MockObject Gets the visitor mock.
internalGetVisitor ( ) : ValueObjectVisitor Must return an instance of the tested visitor object.
resetRouterMock ( ) Resets the router mock and its expected calls index & list.

Method Details

addRouteExpectation() protected method

Adds an expectation to the routerMock. Expectations must be added sequentially.
protected addRouteExpectation ( string $routeName, array $arguments, string $returnValue )
$routeName string
$arguments array
$returnValue string

addTemplatedRouteExpectation() protected method

Adds an expectation to the templatedRouterMock. Expectations must be added sequentially.
protected addTemplatedRouteExpectation ( string $routeName, array $arguments, string $returnValue )
$routeName string
$arguments array
$returnValue string

assertXPath() protected method

This method asserts that $xpathExpression results in a non-empty node set in context of $domNode, by wrapping the "boolean()" function around it and evaluating it on the document owning $domNode.
protected assertXPath ( DOMNode $domNode, string $xpathExpression )
$domNode DOMNode
$xpathExpression string

getGenerator() protected method

Gets the output generator.
protected getGenerator ( ) : Xml
return eZ\Publish\Core\REST\Common\Output\Generator\Xml

getRequestParser() protected method

protected getRequestParser ( ) : eZ\Publish\Core\REST\Common\RequestParser | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\Core\REST\Common\RequestParser | PHPUnit_Framework_MockObject_MockObject

getResponseMock() protected method

protected getResponseMock ( ) : Response | PHPUnit_Framework_MockObject_MockObject
return Symfony\Component\HttpFoundation\Response | PHPUnit_Framework_MockObject_MockObject

getRouterMock() protected method

protected getRouterMock ( ) : Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject
return Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject

getTemplatedRouterMock() protected method

protected getTemplatedRouterMock ( ) : Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject
return Symfony\Component\Routing\RouterInterface | PHPUnit_Framework_MockObject_MockObject

getVisitor() protected method

protected getVisitor ( )

getVisitorMock() protected method

Gets the visitor mock.
protected getVisitorMock ( ) : Visitor | PHPUnit_Framework_MockObject_MockObject
return eZ\Publish\Core\REST\Common\Output\Visitor | PHPUnit_Framework_MockObject_MockObject

internalGetVisitor() abstract protected method

Must return an instance of the tested visitor object.
abstract protected internalGetVisitor ( ) : ValueObjectVisitor
return eZ\Publish\Core\REST\Common\Output\ValueObjectVisitor

resetRouterMock() protected method

Resets the router mock and its expected calls index & list.
protected resetRouterMock ( )

Property Details

$generator protected_oe property

Output generator.
protected Xml,eZ\Publish\Core\REST\Common\Output\Generator $generator
return eZ\Publish\Core\REST\Common\Output\Generator\Xml

$requestParser protected_oe property

protected RequestParser,eZ\Publish\Core\REST\Common $requestParser
return eZ\Publish\Core\REST\Common\RequestParser

$visitorMock protected_oe property

Visitor mock.
protected Visitor,eZ\Publish\Core\REST\Common\Output $visitorMock
return eZ\Publish\Core\REST\Common\Output\Visitor