-
Notifications
You must be signed in to change notification settings - Fork 7.8k
fix bug 63392 #224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix bug 63392 #224
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--TEST-- | ||
Bug #63392 (DateTime::modify() start of week inconsistency) | ||
Description: | ||
------------ | ||
|
||
|
||
--INI-- | ||
date.timezone=UTC | ||
--FILE-- | ||
<?php | ||
|
||
$dt = new DateTime("2012-05-13"); | ||
$dt->modify("Sunday this week"); | ||
var_dump($dt->format('r')); | ||
?> | ||
--EXPECT-- | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The output is timezone dependent, you could add a timezone section, eg:
on my machine test failed before set timezone:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. php's version that you used is error plesae use the last version. php 5.3.x will cause timezone dependent There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I use PHP5.4-lastest and test should pass in all currently maintained version :) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. my mistake ,you are right,many php version on my PC,i confuse the version,sorry. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. already add ini date.timezone=UTC. |
||
string(31) "Sun, 13 May 2012 00:00:00 +0000" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You could use DESCRIPTION Section like this:
https://github.com/php/php-src/blob/master/Zend/tests/bug60825.phpt#L1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I already corrent the mistake that you said above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here, I mean you could move the description to a new section, or it will output with the test name, that looks ugly :)
--DESCRIPTION--
......