You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A call to a moment function was using relative time, and it has been two years since the date specified, so it started providing a different value, which has caused the test snapshot to break. I've mocked the moment prototype in the test file and it has resolved the problem for me locally.
Checklist
Delete any items that are not applicable to this PR.
tylersmalley
changed the title
[Uptime] Unskip ping histogram unit test
[Uptime] Fix ping histogram unit test
Jul 28, 2020
tylersmalley
changed the title
[Uptime] Fix ping histogram unit test
[Uptime] Mock prototype in unit test to prevent relative date breaking snapshots.
Jul 28, 2020
Friendly reminder: Looks like this PR hasn’t been backported yet.
To create backports run node scripts/backport --pr 73531 or prevent reminders by adding the backport:skip label.
Friendly reminder: Looks like this PR hasn’t been backported yet.
To create backports run node scripts/backport --pr 73531 or prevent reminders by adding the backport:skip label.
Friendly reminder: Looks like this PR hasn’t been backported yet.
To create backports run node scripts/backport --pr 73531 or prevent reminders by adding the backport:skip label.
I've applied backport:skip to avoid the bot notifying on this branch. Based on the comment above, the fix was ported to all necessary release branches.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #73522.
A call to a
momentfunction was using relative time, and it has been two years since the date specified, so it started providing a different value, which has caused the test snapshot to break. I've mocked the moment prototype in the test file and it has resolved the problem for me locally.Checklist
Delete any items that are not applicable to this PR.
For maintainers