Skip to content

chore(ui5-date-picker, ui5-range-slider): use i18n bundle in tests instead of hardcoded strings#13529

Merged
ilhan007 merged 1 commit into
mainfrom
fix/test-i18n-hardcoded-strings
May 15, 2026
Merged

chore(ui5-date-picker, ui5-range-slider): use i18n bundle in tests instead of hardcoded strings#13529
ilhan007 merged 1 commit into
mainfrom
fix/test-i18n-hardcoded-strings

Conversation

@ilhan007
Copy link
Copy Markdown
Contributor

Summary

  • Replaces hardcoded accessible name strings in DatePicker and RangeSlider tests with i18nBundle.getText() calls
  • Tests now dynamically resolve the expected text from the message bundle, making them resilient to translation updates

Root cause

Both caused failures on the Translation Delivery PR #13427.

Changes

File Fix
DatePicker.cy.tsx Use DatePicker.i18nBundle.getText(DATEPICKER_POPOVER_ACCESSIBLE_NAME, label)
RangeSlider.cy.tsx Use RangeSlider.i18nBundle.getText(RANGE_SLIDER_START_HANDLE_DESCRIPTION) / RANGE_SLIDER_END_HANDLE_DESCRIPTION

Test plan

  • yarn test:cypress:single cypress/specs/DatePicker.cy.tsx passes (suite-2)
  • yarn test:cypress:single cypress/specs/RangeSlider.cy.tsx passes (suite-3)

Fixes CI failures in #13427.

…ead of hardcoded strings

Replace hardcoded accessible name assertions with i18nBundle.getText()
calls so tests remain stable across translation updates.
@ilhan007 ilhan007 changed the title fix(ui5-date-picker, ui5-range-slider): use i18n bundle in tests instead of hardcoded strings chore(ui5-date-picker, ui5-range-slider): use i18n bundle in tests instead of hardcoded strings May 15, 2026
@ilhan007 ilhan007 merged commit 5316ed9 into main May 15, 2026
25 of 27 checks passed
@ilhan007 ilhan007 deleted the fix/test-i18n-hardcoded-strings branch May 15, 2026 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants