private function PHPUnit_Framework_Constraint_IsInstanceOf::getType in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php \PHPUnit_Framework_Constraint_IsInstanceOf::getType()
2 calls to PHPUnit_Framework_Constraint_IsInstanceOf::getType()
- PHPUnit_Framework_Constraint_IsInstanceOf::failureDescription in vendor/
phpunit/ phpunit/ src/ Framework/ Constraint/ IsInstanceOf.php - Returns the description of the failure
- PHPUnit_Framework_Constraint_IsInstanceOf::toString in vendor/
phpunit/ phpunit/ src/ Framework/ Constraint/ IsInstanceOf.php - Returns a string representation of the constraint.
File
- vendor/
phpunit/ phpunit/ src/ Framework/ Constraint/ IsInstanceOf.php, line 80
Class
- PHPUnit_Framework_Constraint_IsInstanceOf
- Constraint that asserts that the object it is evaluated for is an instance of a given class.
Code
private function getType() {
try {
$reflection = new ReflectionClass($this->className);
if ($reflection
->isInterface()) {
return 'interface';
}
} catch (ReflectionException $e) {
}
return 'class';
}