Skip to content

test(i18n): enforce CLDR plural completeness - #720

Merged
lilyshen0722 merged 1 commit into
mainfrom
codex/i18n-plural-completeness
Jul 22, 2026
Merged

test(i18n): enforce CLDR plural completeness#720
lilyshen0722 merged 1 commit into
mainfrom
codex/i18n-plural-completeness

Conversation

@lilyshen0722

Copy link
Copy Markdown
Contributor

Summary

  • compare locale catalogs by normalized plural base keys instead of misleading raw path equality
  • assert every pluralized key provides each CLDR category required by that locale
  • add four English singular forms the new guard immediately exposed

English now has 929 raw paths and zh-CN has 925 by design: English requires _one and _other, while zh-CN requires only _other; normalized base-key parity remains exact. No Chinese copy changed.

Verification

  • npm test -- --runInBand src/i18n/__tests__/translationKeys.test.ts
  • npm test -- --runInBand src/i18n
  • npm test -- --runInBand — 61 suites, 267 tests
  • npx eslint --quiet src/i18n/__tests__/translationKeys.test.ts
  • git diff --check

npm run typecheck remains blocked by three pre-existing errors in V2GithubPrCard.tsx and V2MessageBubble.tsx, outside this diff.

@lilyshen0722
lilyshen0722 merged commit dd851b2 into main Jul 22, 2026
10 checks passed
@lilyshen0722
lilyshen0722 deleted the codex/i18n-plural-completeness branch July 22, 2026 19:43
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.

1 participant