From 4982705d0723df5c7413ed610f50afb73bcbed82 Mon Sep 17 00:00:00 2001 From: predominant Date: Tue, 13 Apr 2010 15:06:44 +1000 Subject: [PATCH] More time helper test jiggering. Some peope still experiencing issues. --- cake/tests/cases/libs/view/helpers/time.test.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/cake/tests/cases/libs/view/helpers/time.test.php b/cake/tests/cases/libs/view/helpers/time.test.php index ba7b12f87..47c26c169 100644 --- a/cake/tests/cases/libs/view/helpers/time.test.php +++ b/cake/tests/cases/libs/view/helpers/time.test.php @@ -661,9 +661,7 @@ class TimeHelperTest extends CakeTestCase { 'locales' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'locale' . DS) ), true); Configure::write('Config.language', 'time_test'); - $time = 1263487419; // Thu Jan 14 11:43:39 2010 - $offset = 5 * 60 * 60; - $time = $time - date('Z') - $offset - (date('I', $time) * 60 * 60); + $time = strtotime('Thu Jan 14 11:43:39 2010'); $result = $this->Time->convertSpecifiers('%a', $time); $expected = 'jue'; @@ -753,9 +751,7 @@ class TimeHelperTest extends CakeTestCase { 'locales' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'locale' . DS) ), true); Configure::write('Config.language', 'time_test'); - $time = 1263495568; //Thu Jan 14 13:59:28 2010 - $offset = 5 * 60 * 60; - $time = $time - date('Z') - $offset - (date('I', $time) * 60 * 60); + $time = strtotime('Thu Jan 14 13:59:28 2010'); $result = $this->Time->i18nFormat($time); $expected = '14/01/10';