rezzza / TimeTraveler

Time traveling php library (pretty similar to ruby timecop)
103 stars 11 forks source link

Test falling in local (passing on travis) #9

Closed armandabric closed 10 years ago

armandabric commented 10 years ago

Some test are failing locally.

Here the trace for PHP 5.4.27 (travis version).

$ bin/atoum
> PHP path: /Users/armandabric/.phpbrew/php/php-5.4.27/bin/php
> PHP version:
=> PHP 5.4.27 (cli) (built: May 16 2014 15:37:04)
=> Copyright (c) 1997-2014 The PHP Group
=> Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies
> tests\units\Rezzza\TimeTraveler...
[SSSFF_______________________________________________________][5/5]
=> Test duration: 0.01 second.
=> Memory usage: 0.00 Mb.
> Total test duration: 0.01 second.
> Total test memory usage: 0.00 Mb.
> Running duration: 0.14 second.
Failure (1 test, 5/5 methods, 0 void method, 0 skipped method, 0 uncompleted method, 2 failures, 0 error, 0 exception)!
> There are 2 failures:
=> tests\units\Rezzza\TimeTraveler::testTime():
In file /Users/armandabric/workspace/TimeTraveler/tests/units/Rezzza/TimeTraveler.php on line 73, mageekguy\atoum\asserters\integer() failed for data set #0 of data provider timeDataProvider: integer(1369432800) is not identical to integer(1369440000)
-Expected
+Actual
@@ -1 +1 @@
-int(1369440000)
+int(1369432800)
=> tests\units\Rezzza\TimeTraveler::testMicrotime():
In file /Users/armandabric/workspace/TimeTraveler/tests/units/Rezzza/TimeTraveler.php on line 94, mageekguy\atoum\asserters\integer() failed for data set #0 of data provider microtimeDataProvider: integer(1369432800) is not equal to integer(1369440000)
-Expected
+Actual
@@ -1 +1 @@
-int(1369440000)
+int(1369432800)
stephpy commented 10 years ago

You are on a branch, it seems master works ?

armandabric commented 10 years ago

I'm on master.

armandabric commented 10 years ago

Idea: check date.timezone config.

stephpy commented 10 years ago

Yes, this is the problem, i'm investigating.

stephpy commented 10 years ago

Fixed on befb2bb04c5c8e753ad847dfe279adf53eadc91d