Skip to content

Conversation

@mgadewoll
Copy link
Contributor

@mgadewoll mgadewoll commented Jan 6, 2025

Summary

This PR updates the EuiSuperdatePicker absolute_tab.test.tsx test by adding a year to the passed date string to prevent tests breaking on yearly changing week days.

Example failing test:

EuiAbsoluteTab › date parsing › parses date string in locale › {"dateString": "lun. janv. 1er", "locale": "fr-FR"}

The issue was that January 1st was a Monday in 2024, but is not a Monday in 2025.
We should fix the date to the year to ensure the test works generally.

QA

  • CI passes
  • verify tests pass
    • checkout this PR
    • move to packages/eui and run yarn test-unit src/components/date_picker/super_date_picker/date_popover/absolute_tab.test.tsx

@mgadewoll mgadewoll marked this pull request as ready for review January 6, 2025 16:09
@mgadewoll mgadewoll requested a review from a team as a code owner January 6, 2025 16:09
@mgadewoll mgadewoll force-pushed the superdatepicker/fix-date-string-locale-test branch from 3fb401d to 96eeec5 Compare January 6, 2025 23:49
@mgadewoll mgadewoll added the skip-changelog Use on PRs to skip changelog requirement (Don't delete - used for automation) label Jan 6, 2025
@kibanamachine
Copy link

Preview staging links for this PR:

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

Copy link
Contributor

@acstll acstll left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Passes locally for me. LGTM 👌

@mgadewoll mgadewoll merged commit c8522d9 into elastic:main Jan 7, 2025
7 of 9 checks passed
@mgadewoll mgadewoll deleted the superdatepicker/fix-date-string-locale-test branch January 7, 2025 09:54
mgadewoll added a commit to mgadewoll/eui that referenced this pull request Jan 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-changelog Use on PRs to skip changelog requirement (Don't delete - used for automation)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants