PHPUnit
PHPUnit TYPO3 extension
Protected Member Functions | Protected Attributes | List of all members
Tx_Phpunit_TestCase Class Reference
Inheritance diagram for Tx_Phpunit_TestCase:
Tx_Phpunit_Database_TestCase

Protected Member Functions

 getAccessibleMock ($originalClassName, array $methods=array(), array $arguments=array(), $mockClassName= '', $callOriginalConstructor=TRUE, $callOriginalClone=TRUE, $callAutoload=TRUE)
 
 buildAccessibleProxy ($className)
 

Protected Attributes

 $backupGlobals = FALSE
 
 $backupStaticAttributes = FALSE
 

Member Function Documentation

Tx_Phpunit_TestCase::buildAccessibleProxy (   $className)
protected

Creates a proxy class of the specified class which allows for calling even protected methods and access of protected properties.

Parameters
string$classNamename of class to make available, must not be empty
Returns
string full qualified name of the built class, will not be empty
See also
Tx_Extbase_Tests_Unit_BaseTestCase::buildAccessibleProxy
Tx_Phpunit_TestCase::getAccessibleMock (   $originalClassName,
array  $methods = array(),
array  $arguments = array(),
  $mockClassName = '',
  $callOriginalConstructor = TRUE,
  $callOriginalClone = TRUE,
  $callAutoload = TRUE 
)
protected

Creates a mock object which allows for calling protected methods and access of protected properties.

Parameters
string$originalClassNamename of class to create the mock object of, must not be empty
string[]$methods name of the methods to mock
array$argumentsarguments to pass to constructor
string$mockClassNamethe class name to use for the mock class
bool$callOriginalConstructorwhether to call the constructor
bool$callOriginalClonewhether to call the __clone method
bool$callAutoloadwhether to call any autoload function
Returns
PHPUnit_Framework_MockObject_MockObject|Tx_Phpunit_Interface_AccessibleObject a mock of $originalClassName with access methods added
Exceptions
InvalidArgumentException
See also
Tx_Extbase_Tests_Unit_BaseTestCase::getAccessibleMock

The documentation for this class was generated from the following file: