Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix more off by a second errors

  • Loading branch information...
commit 94bd2cedcf139eba5718016231d15e2d7fffe079 1 parent ab2ce29
@markstory markstory authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/Cake/Test/Case/Utility/CakeTimeTest.php
View
8 lib/Cake/Test/Case/Utility/CakeTimeTest.php
@@ -340,14 +340,14 @@ public function testNice() {
$this->assertEquals(date('Y-d-m', $time), $this->Time->nice($time));
$this->assertEquals('%Y-%d-%m', $this->Time->niceFormat);
- CakeTime::$niceFormat = '%Y-%d-%m %H:%M:%S';
- $this->assertEquals(date('Y-d-m H:i:s', $time), $this->Time->nice($time));
- $this->assertEquals('%Y-%d-%m %H:%M:%S', $this->Time->niceFormat);
+ CakeTime::$niceFormat = '%Y-%d-%m %H:%M';
+ $this->assertEquals(date('Y-d-m H:i', $time), $this->Time->nice($time));
+ $this->assertEquals('%Y-%d-%m %H:%M', $this->Time->niceFormat);
date_default_timezone_set('UTC');
$result = $this->Time->nice(null, 'America/New_York');
$expected = $this->Time->nice(time(), 'America/New_York');
- $this->assertEquals($expected, $result);
+ $this->assertEquals(substr($expected, 0, -1), substr($result, 0, -1));
$this->_restoreSystemTimezone();
}
Please sign in to comment.
Something went wrong with that request. Please try again.