Commit 4cb8fdfd authored by Markus Kalkbrenner's avatar Markus Kalkbrenner

fixes #600

parent 68bc9c47
...@@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ...@@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
### Removed ### Removed
### Fixed ### Fixed
- Random test failures caused by different timestamps
### Security ### Security
......
...@@ -302,14 +302,15 @@ class HelperTest extends TestCase ...@@ -302,14 +302,15 @@ class HelperTest extends TestCase
public function testFormatDate() public function testFormatDate()
{ {
$timestamp = time();
//check if timezone is stripped //check if timezone is stripped
$expected = strtoupper('Z'); $expected = strtoupper('Z');
$actual = substr($this->helper->formatDate(time()), 19, 20); $actual = substr($this->helper->formatDate($timestamp), 19, 20);
$this->assertSame($expected, $actual, 'Expects last charachter to be uppercased Z'); $this->assertSame($expected, $actual, 'Expects last charachter to be uppercased Z');
$this->assertSame( $this->assertSame(
$this->mockFormatDateOutput(time()), $this->mockFormatDateOutput($timestamp),
$this->helper->formatDate(time()) $this->helper->formatDate($timestamp)
); );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment