Skip to content
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

Re-fix test #18009

Merged
merged 1 commit into from
Jul 31, 2020
Merged

Re-fix test #18009

merged 1 commit into from
Jul 31, 2020

Conversation

eileenmcnaughton
Copy link
Contributor

Overview

Fix for flakey test

Before

Test fails at the end of some months, notably this one

After

Less flakey

Technical Details

The strtotime calculation adds 4 months before setting the day of month. However

July 31 + 4 months is 1 Dec - ie the month is 12 not 11 due to there being only 30 days. So to
get 27 Nov we need to get the July month (7) and add 4 and voila 11, not 12

Comments

@civibot
Copy link

civibot bot commented Jul 31, 2020

(Standard links)

The strtotime calculation adds 4 months before setting the day of month. However

July 31 + 4 months is 1 Dec - ie the month is 12 not 11 due to there being only 30 days. So to
get 27 Nov we need to get the July month (7) and add 4 and voila 11, not 12
@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 can you merge this'

@seamuslee001
Copy link
Contributor

Looks fine to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants