Chris@14: addToAssertionCount(1); Chris@14: } Chris@14: Chris@14: public function testCallingOtherErrorHandler() Chris@14: { Chris@14: $class = class_exists('PHPUnit\Framework\Exception') ? 'PHPUnit\Framework\Exception' : 'PHPUnit_Framework_Exception'; Chris@14: if (method_exists($this, 'expectException')) { Chris@14: $this->expectException($class); Chris@14: $this->expectExceptionMessage('Test that PHPUnit\'s error handler fires.'); Chris@14: } else { Chris@14: $this->setExpectedException($class, 'Test that PHPUnit\'s error handler fires.'); Chris@14: } Chris@14: Chris@14: trigger_error('Test that PHPUnit\'s error handler fires.', E_USER_WARNING); Chris@14: } Chris@14: }