Ticket #3416: sfBrowser.patch
| File sfBrowser.patch, 1.6 kB (added by Kris.Wallsmith, 9 months ago) |
|---|
-
lib/test/sfTestBrowser.class.php
old new 383 383 384 384 return $this; 385 385 } 386 387 /** 388 * Trigger a test failure if an uncaught exception is present. 389 * 390 * @return boolean 391 */ 392 public function checkCurrentExceptionIsEmpty() 393 { 394 if (false === ($empty = parent::checkCurrentExceptionIsEmpty())) 395 { 396 $this->test()->fail(sprintf('last request threw an uncatched exception "%s: %s"', get_class($this->getCurrentException()), $this->getCurrentException()->getMessage())); 397 } 398 399 return $empty; 400 } 386 401 387 402 /** 388 403 * Tests if the given uri is cached. -
lib/util/sfBrowser.class.php
old new 458 458 $this->currentException = null; 459 459 } 460 460 461 /** 462 * Test for an uncaught exception. 463 * 464 * @return boolean 465 */ 461 466 public function checkCurrentExceptionIsEmpty() 462 467 { 463 if (is_null($this->getCurrentException()) || $this->getCurrentException() instanceof sfError404Exception) 464 { 465 return; 466 } 467 468 $this->test->fail(sprintf('last request threw an uncatched exception "%s: %s"', get_class($this->getCurrentException()), $this->getCurrentException()->getMessage())); 468 return is_null($this->getCurrentException()) || $this->getCurrentException() instanceof sfError404Exception; 469 469 } 470 470 471 471 /**