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

ICU-22920 Fix raw type warnings in icu4j core tests #3305

Merged
merged 1 commit into from
Dec 15, 2024

Conversation

mihnita
Copy link
Contributor

@mihnita mihnita commented Dec 13, 2024

To make the review easier this only fixes one kind of warning:
XYZ is a raw type. References to generic type XYZ should be parameterized.

This PR removes about 440 warnings.

Only fixed the warnings in tests, leaving the main code untouched.

The non-test code might needs a bit more care.
Some might be implementation details, private methods / members, easy to change.
But some might affect public APIs


There is also a leftover class in tests that need fixing.

LocaleAliasTest fails if I fix it, because it is already broken, but no tests run.

There is a generic (typeless) Map, initialized with some String (key) => Strings (value).

Later on there are get(ULocale) calls, which return null, and that test case if skipped.
So no test is executed, because in fact all test cases are skipped.

If I fix the type of the map to <ULocale, ULocale> (as it should be), then the real tests are executed and some are failing.

Checklist

  • Required: Issue filed: ICU-22920
  • Required: The PR title must be prefixed with a JIRA Issue number. Example: "ICU-1234 Fix xyz"
  • Required: The PR description must include the link to the Jira Issue, for example by completing the URL in the first checklist item
  • Required: Each commit message must be prefixed with a JIRA Issue number. Example: "ICU-1234 Fix xyz"
  • Issue accepted (done by Technical Committee after discussion)
  • Tests included, if applicable
  • API docs and/or User Guide docs changed or added, if applicable

@mihnita mihnita requested a review from markusicu December 14, 2024 08:35
@mihnita mihnita force-pushed the mihai_reduce_warnings_22920 branch from a5175cf to 58ca679 Compare December 15, 2024 08:52
@jira-pull-request-webhook
Copy link

Hooray! The files in the branch are the same across the force-push. 😃

~ Your Friendly Jira-GitHub PR Checker Bot

@mihnita mihnita merged commit 4ff5d6a into unicode-org:main Dec 15, 2024
15 checks passed
@mihnita mihnita deleted the mihai_reduce_warnings_22920 branch December 15, 2024 09:20
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.

3 participants