protected function PHPUnit_Framework_Constraint_Not::failureDescription in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/phpunit/phpunit/src/Framework/Constraint/Not.php \PHPUnit_Framework_Constraint_Not::failureDescription()
Returns the description of the failure
The beginning of failure messages is "Failed asserting that" in most cases. This method should return the second part of that sentence.
Parameters
mixed $other Evaluated value or object.:
Return value
string
Overrides PHPUnit_Framework_Constraint::failureDescription
File
- vendor/
phpunit/ phpunit/ src/ Framework/ Constraint/ Not.php, line 110
Class
- PHPUnit_Framework_Constraint_Not
- Logical NOT.
Code
protected function failureDescription($other) {
switch (get_class($this->constraint)) {
case 'PHPUnit_Framework_Constraint_And':
case 'PHPUnit_Framework_Constraint_Not':
case 'PHPUnit_Framework_Constraint_Or':
return 'not( ' . $this->constraint
->failureDescription($other) . ' )';
default:
return self::negate($this->constraint
->failureDescription($other));
}
}