[Apple-Mobile][Globalization] Refactoring of CalendarData.iOS and new DateTimeFormatInfo* tests#102464
Merged
matouskozak merged 19 commits intodotnet:mainfrom Jul 12, 2024
Merged
Conversation
Contributor
|
Tagging subscribers to this area: @dotnet/area-system-globalization |
Contributor
|
Draft Pull Request was automatically closed for 30 days of inactivity. Please let us know if you'd like to reopen it. |
|
Azure Pipelines successfully started running 1 pipeline(s). |
This was referenced Jul 5, 2024
ilonatommy
approved these changes
Jul 8, 2024
src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.Icu.cs
Show resolved
Hide resolved
mkhamoyan
reviewed
Jul 9, 2024
src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.iOS.cs
Show resolved
Hide resolved
mkhamoyan
approved these changes
Jul 9, 2024
Contributor
mkhamoyan
left a comment
There was a problem hiding this comment.
Looks good to me. Thanks for cleaning it up!
tarekgh
reviewed
Jul 10, 2024
...tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs
Outdated
Show resolved
Hide resolved
tarekgh
reviewed
Jul 10, 2024
...tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs
Outdated
Show resolved
Hide resolved
tarekgh
approved these changes
Jul 10, 2024
Member
tarekgh
left a comment
There was a problem hiding this comment.
I have added minor comments. Please ensure to apply that on all added tests. LGTM otherwise.
Member
Author
|
/azp run runtime-extra-platforms |
|
Azure Pipelines successfully started running 1 pipeline(s). |
This was referenced Jul 11, 2024
Build failure: Static graph-based restore failed with exit code .* but did not log an error.
#103526
Closed
Member
Author
|
The extra-platform failures are known and are tracked at: #103472. The |
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
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Description
This PR has 3 components:
1. Refactoring of
CalendarData.iOS.csThe goal was to unify logic with
CalendarData.ICU. Eventually it should be possible to fully merge these two together.2. Fix of
DateTimeFormatInfo.LongDatePatternAPI:The previously returned format was incorrect. Previously we were returning the
NSDateFormatterLongStyle. However, for .NET theLongDatePattern(https://learn.microsoft.com/en-us/dotnet/api/system.globalization.datetimeformatinfo.longdatepattern?view=net-8.0) corresponds toNSDateFormatterFullStyle(https://developer.apple.com/documentation/foundation/nsdateformatterstyle/nsdateformatterfullstyle).3. Adding new test cases for
DateTimeFormatInfo*APIsMany of
DateTimeFormatInfo*APIs were only tested inInvartianGlobalizationsettings before. The following tests were added for platforms with ICU globalization:DateTimeFormatInfoAbbreviatedDayNames(en-US,fr-FR)DateTimeFormatInfoAbbreviatedMonthGenitiveNames(en-US,fr-FR)DateTimeFormatInfoAbbreviatedMonthNames(en-US,fr-FR)DateTimeFormatInfoDayNames(en-US,fr-FR)DateTimeFormatInfoLongDatePattern(en-US,fr-FR)DateTimeFormatInfoMonthDayPattern(en-US,fr-FR)DateTimeFormatInfoMonthGenitiveNames(en-US,fr-FR)DateTimeFormatInfoMonthNames(en-US,fr-FR)The
en-US,fr-FRlocales were selected because they are generally the most stable between ICU versions.Contributes to #100240