Skip to content

Commit

Permalink
Merge pull request #913 from Vinai/data-form-element-datetest
Browse files Browse the repository at this point in the history
Specify date fixture and fix expectations (MAGETWO-32328)
  • Loading branch information
maksek committed Jan 6, 2015
2 parents 3fd135e + 1d7b54a commit ce71c37
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,29 +48,29 @@ public function testGetValue(array $data, $expect)
*/
public function getValueDataProvider()
{
$currentTime = time();
$testTimestamp = strtotime('2014-05-18 12:08:16');
return [
[
[
'date_format' => \Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_SHORT,
'time_format' => \Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_SHORT,
'value' => $currentTime,
'value' => $testTimestamp,
],
date('m/j/y g:i A', $currentTime),
date('n/j/y g:i A', $testTimestamp),
],
[
[
'time_format' => \Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_SHORT,
'value' => $currentTime,
'value' => $testTimestamp,
],
date('g:i A', $currentTime)
date('g:i A', $testTimestamp)
],
[
[
'date_format' => \Magento\Framework\Stdlib\DateTime\TimezoneInterface::FORMAT_TYPE_SHORT,
'value' => $currentTime,
'value' => $testTimestamp,
],
date('m/j/y', $currentTime)
date('n/j/y', $testTimestamp)
]
];
}
Expand Down

0 comments on commit ce71c37

Please sign in to comment.