Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Maybe bug in testMoscowWinterTime #257

@icetee

Description

@icetee

I send another topic pull request and failed the testMoscowWinterTime. The test did not run before midnight, it runs smoothly after midnight. (Can be triggered by clock setting.)

1) ZendTest\Validator\DateStepTest::testMoscowWinterTime with data set #2 ('27-03-2011')
Failed asserting that false is true.

/home/travis/build/zendframework/zend-validator/test/DateStepTest.php:151

I don't know the code so much, but UTC was always good on the local machine.

$date = DateTime::createFromFormat($this->format, $value, $this->timezone);

change to

$date = DateTime::createFromFormat($this->format, $value, new DateTimeZone('UTC'));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions