Skip to content
Permalink
Browse files

Fixing skip in previous commit: if skip condition evaluates to true, …

…to prevent a fatal error from being produced.
  • Loading branch information...
jperras committed Oct 19, 2009
1 parent daafac8 commit ae342c6f2c9e88290cdc4316bff7848a3a4a908e
Showing with 4 additions and 1 deletion.
  1. +4 −1 cake/tests/cases/libs/view/helpers/time.test.php
@@ -639,7 +639,10 @@ function testWasWithinLast() {
* @return void
*/
function testUserOffset() {
$this->skipIf(!class_exists('DateTimeZone'), '%s DateTimeZone class not available.');
if ($this->skipIf(!class_exists('DateTimeZone'), '%s DateTimeZone class not available.')) {
return;
}
$timezoneServer = new DateTimeZone(date_default_timezone_get());
$timeServer = new DateTime('now', $timezoneServer);

0 comments on commit ae342c6

Please sign in to comment.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.