Skip to content
This repository
Browse code

DateTime::getTimestamp() only exists in PHP > 5.3.0

  • Loading branch information...
commit 667dfd308f25db57e8ee4a3e3877dbff0844035b 1 parent e8f727f
Mark Story authored October 27, 2012
2  lib/Cake/Test/Case/Utility/CakeTimeTest.php
@@ -518,7 +518,7 @@ public function testToRss() {
518 518
 			$yourTimezone = new DateTimeZone($timezone);
519 519
 			$yourTime = new DateTime($date, $yourTimezone);
520 520
 			$userOffset = $yourTimezone->getOffset($yourTime) / HOUR;
521  
-			$time = $yourTime->getTimestamp();
  521
+			$time = $yourTime->format('U');
522 522
 			$this->assertEquals($yourTime->format('r'), $this->Time->toRss($time, $userOffset), "Failed on $timezone");
523 523
 			$this->assertEquals($yourTime->format('r'), $this->Time->toRss($time, $timezone), "Failed on $timezone");
524 524
 		}

0 notes on commit 667dfd3

Please sign in to comment.
Something went wrong with that request. Please try again.