diff --git a/docs/design/features/globalization-hybrid-mode.md b/docs/design/features/globalization-hybrid-mode.md index 1dec94595b1c4..9840c30fed0bb 100644 --- a/docs/design/features/globalization-hybrid-mode.md +++ b/docs/design/features/globalization-hybrid-mode.md @@ -11,382 +11,6 @@ Hybrid has lower priority than Invariant. To switch on the mode set the property Hybrid mode does not use ICU data for some functions connected with globalization but relies on functions native to the platform. Because native APIs do not fully cover all the functionalities we currently support and because ICU data can be excluded from the ICU datafile only in batches defined by ICU filters, not all functions will work the same way or not all will be supported. To see what to expect after switching on `HybridGlobalization`, read the following paragraphs. -### WASM - -For WebAssembly in Browser we are using Web API instead of some ICU data. Ideally, we would use `System.Runtime.InteropServices.JavaScript` to call JS code from inside of C# but we cannot reference any assemblies from inside of `System.Private.CoreLib`. That is why we are using iCalls instead. The host support depends on used Web API functions support - see **dependencies** in each section. - -Hybrid has higher priority than sharding or custom modes, described in globalization-icu-wasm.md. - -**HashCode** - -Affected public APIs: -- System.Globalization.CompareInfo.GetHashCode - -For invariant culture all `CompareOptions` are available. - -For non-invariant cultures following `CompareOptions` are available: -- `CompareOption.None` -- `CompareOption.IgnoreCase` - -The remaining combinations for non-invariant cultures throw `PlatformNotSupportedException`. - -**SortKey** - -Affected public APIs: -- System.Globalization.CompareInfo.GetSortKey -- System.Globalization.CompareInfo.GetSortKeyLength - -For invariant culture all `CompareOptions` are available. - -For non-invariant cultures `PlatformNotSupportedException` is thrown. - -Indirectly affected APIs (the list might not be complete): -- Microsoft.VisualBasic.Collection.Add -- System.Collections.Hashtable.Add -- System.Collections.Hashtable.GetHash -- System.Collections.CaseInsensitiveHashCodeProvider.GetHashCode -- System.Collections.Specialized.NameObjectCollectionBase.BaseAdd -- System.Collections.Specialized.NameValueCollection.Add -- System.Collections.Specialized.NameObjectCollectionBase.BaseGet -- System.Collections.Specialized.NameValueCollection.Get -- System.Collections.Specialized.NameObjectCollectionBase.BaseRemove -- System.Collections.Specialized.NameValueCollection.Remove -- System.Collections.Specialized.OrderedDictionary.Add -- System.Collections.Specialized.NameObjectCollectionBase.BaseSet -- System.Collections.Specialized.NameValueCollection.Set -- System.Data.DataColumnCollection.Add -- System.Collections.Generic.HashSet -- System.Collections.Generic.Dictionary -- System.Net.Mail.MailAddress.GetHashCode -- System.Xml.Xsl.XslCompiledTransform.Transform - -**Case change** - -Affected public APIs: -- System.Globalization.TextInfo.ToLower, -- System.Globalization.TextInfo.ToUpper, -- System.Globalization.TextInfo.ToTitleCase. - -Case change with invariant culture uses `toUpperCase` / `toLoweCase` functions that do not guarantee a full match with the original invariant culture. -Hybrid case change, same as ICU-based, does not support code points expansion e.g. "straße" -> "STRAßE". - -- Final sigma behavior correction: - -ICU-based case change does not respect final-sigma rule, but hybrid does, so "ΒΌΛΟΣ" -> "βόλος", not "βόλοσ". - -Dependencies: -- [String.prototype.toUpperCase()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toUpperCase) -- [String.prototype.toLoweCase()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toLowerCase) -- [String.prototype.toLocaleUpperCase()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toLocaleUpperCase) -- [String.prototype.toLocaleLoweCase()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toLocaleLowerCase) - -**String comparison** - -Affected public APIs: -- System.Globalization.CompareInfo.Compare, -- System.String.Compare, -- System.String.Equals. -Indirectly affected APIs (the list might not be complete): -- Microsoft.VisualBasic.Strings.InStrRev -- Microsoft.VisualBasic.Strings.Replace -- Microsoft.VisualBasic.Strings.InStr -- Microsoft.VisualBasic.Strings.Split -- Microsoft.VisualBasic.Strings.StrComp -- Microsoft.VisualBasic.CompilerServices.LikeOperator.LikeObject -- Microsoft.VisualBasic.CompilerServices.LikeOperator.LikeString -- Microsoft.VisualBasic.CompilerServices.ObjectType.ObjTst -- Microsoft.VisualBasic.CompilerServices.ObjectType.LikeObj -- Microsoft.VisualBasic.CompilerServices.StringType.StrLike -- Microsoft.VisualBasic.CompilerServices.Operators.ConditionalCompareObjectEqual -- Microsoft.VisualBasic.CompilerServices.StringType.StrLike -- Microsoft.VisualBasic.CompilerServices.StringType.StrLikeText -- Microsoft.VisualBasic.CompilerServices.StringType.StrCmp -- System.Data.DataSet.ReadXml -- System.Data.DataTableCollection.Add - -Dependencies: -- [String.prototype.localeCompare()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/localeCompare) - -The number of `CompareOptions` and `StringComparison` combinations is limited. Originally supported combinations can be found [here for CompareOptions](https://learn.microsoft.com/dotnet/api/system.globalization.compareoptions) and [here for StringComparison](https://learn.microsoft.com/dotnet/api/system.stringcomparison). - - -- `IgnoreWidth` is not supported because there is no equivalent in Web API. Throws `PlatformNotSupportedException`. -``` JS -let high = String.fromCharCode(65281) // %uff83 = テ -let low = String.fromCharCode(12486) // %u30c6 = テ -high.localeCompare(low, "ja-JP", { sensitivity: "case" }) // -1 ; case: a ≠ b, a = á, a ≠ A; expected: 0 - -let wide = String.fromCharCode(65345) // %uFF41 = a -let narrow = "a" -wide.localeCompare(narrow, "en-US", { sensitivity: "accent" }) // 0; accent: a ≠ b, a ≠ á, a = A; expected: -1 -``` - -For comparison where "accent" sensitivity is used, ignoring some type of character widths is applied and cannot be switched off (see: point about `IgnoreCase`). - -- `IgnoreKanaType`: - -It is always switched on for comparison with locale "ja-JP", even if this comparison option was not set explicitly. - -``` JS -let hiragana = String.fromCharCode(12353) // %u3041 = ぁ -let katakana = String.fromCharCode(12449) // %u30A1 = ァ -let enCmp = hiragana.localeCompare(katakana, "en-US") // -1 -let jaCmp = hiragana.localeCompare(katakana, "ja-JP") // 0 -``` - -For locales different than "ja-JP" it cannot be used separately (no equivalent in Web API) - throws `PlatformNotSupportedException`. - -- `None`: - -No equivalent in Web API for "ja-JP" locale. See previous point about `IgnoreKanaType`. For "ja-JP" it throws `PlatformNotSupportedException`. - -- `IgnoreCase`, `CurrentCultureIgnoreCase`, `InvariantCultureIgnoreCase` - -For `IgnoreCase | IgnoreKanaType`, argument `sensitivity: "accent"` is used. - -``` JS -let hiraganaBig = `${String.fromCharCode(12353)} A` // %u3041 = ぁ -let katakanaSmall = `${String.fromCharCode(12449)} a` // %u30A1 = ァ -hiraganaBig.localeCompare(katakanaSmall, "en-US", { sensitivity: "accent" }) // 0; accent: a ≠ b, a ≠ á, a = A -``` - -Known exceptions: - -| **character 1** | **character 2** | **CompareOptions** | **hybrid globalization** | **icu** | **comments** | -|:---------------:|:---------------:|--------------------|:------------------------:|:-------:|:-------------------------------------------------------:| -| a | `\uFF41` a | IgnoreKanaType | 0 | -1 | applies to all wide-narrow chars | -| `\u30DC` ボ | `\uFF8E` ホ | IgnoreCase | 1 | -1 | 1 is returned in icu when we additionally ignore width | -| `\u30BF` タ | `\uFF80` タ | IgnoreCase | 0 | -1 | | - - -For `IgnoreCase` alone, a comparison with default option: `sensitivity: "variant"` is used after string case unification. - -``` JS -let hiraganaBig = `${String.fromCharCode(12353)} A` // %u3041 = ぁ -let katakanaSmall = `${String.fromCharCode(12449)} a` // %u30A1 = ァ -let unchangedLocale = "en-US" -let unchangedStr1 = hiraganaBig.toLocaleLowerCase(unchangedLocale); -let unchangedStr2 = katakanaSmall.toLocaleLowerCase(unchangedLocale); -unchangedStr1.localeCompare(unchangedStr2, unchangedLocale) // -1; -let changedLocale = "ja-JP" -let changedStr1 = hiraganaBig.toLocaleLowerCase(changedLocale); -let changedStr2 = katakanaSmall.toLocaleLowerCase(changedLocale); -changedStr1.localeCompare(changedStr2, changedLocale) // 0; -``` - -From this reason, comparison with locale `ja-JP` `CompareOption` `IgnoreCase` and `StringComparison`: `CurrentCultureIgnoreCase` and `InvariantCultureIgnoreCase` behave like a combination `IgnoreCase | IgnoreKanaType` (see: previous point about `IgnoreKanaType`). For other locales the behavior is unchanged with the following known exceptions: - -| **character 1** | **character 2** | **CompareOptions** | **hybrid globalization** | **icu** | -|:------------------------------------------------:|:----------------------------------------------------------:|-----------------------------------|:------------------------:|:-------:| -| `\uFF9E` (HALFWIDTH KATAKANA VOICED SOUND MARK) | `\u3099` (COMBINING KATAKANA-HIRAGANA VOICED SOUND MARK) | None / IgnoreCase / IgnoreSymbols | 1 | 0 | - -- `IgnoreNonSpace` - -`IgnoreNonSpace` cannot be used separately without `IgnoreKanaType`. Argument `sensitivity: "case"` is used for comparison and it ignores both types of characters. Option `IgnoreNonSpace` alone throws `PlatformNotSupportedException`. - -``` JS -let hiraganaAccent = `${String.fromCharCode(12353)} á` // %u3041 = ぁ -let katakanaNoAccent = `${String.fromCharCode(12449)} a` // %u30A1 = ァ -hiraganaAccent.localeCompare(katakanaNoAccent, "en-US", { sensitivity: "case" }) // 0; case: a ≠ b, a = á, a ≠ A -``` - -- `IgnoreNonSpace | IgnoreCase` -Combination of `IgnoreNonSpace` and `IgnoreCase` cannot be used without `IgnoreKanaType`. Argument `sensitivity: "base"` is used for comparison and it ignores three types of characters. Combination `IgnoreNonSpace | IgnoreCase` alone throws `PlatformNotSupportedException`. - -``` JS -let hiraganaBigAccent = `${String.fromCharCode(12353)} A á` // %u3041 = ぁ -let katakanaSmallNoAccent = `${String.fromCharCode(12449)} a a` // %u30A1 = ァ -hiraganaBigAccent.localeCompare(katakanaSmallNoAccent, "en-US", { sensitivity: "base" }) // 0; base: a ≠ b, a = á, a = A -``` - -- `IgnoreSymbols` - -The subset of ignored symbols is limited to the symbols ignored by `string1.localeCompare(string2, locale, { ignorePunctuation: true })`. E.g. currency symbols, & are not ignored - -``` JS -let hiraganaAccent = `${String.fromCharCode(12353)} á` // %u3041 = ぁ -let katakanaNoAccent = `${String.fromCharCode(12449)} a` // %u30A1 = ァ -hiraganaBig.localeCompare(katakanaSmall, "en-US", { sensitivity: "base" }) // 0; base: a ≠ b, a = á, a = A -``` - -- List of all `CompareOptions` combinations always throwing `PlatformNotSupportedException`: - -`IgnoreCase`, - -`IgnoreNonSpace`, - -`IgnoreNonSpace | IgnoreCase`, - -`IgnoreSymbols | IgnoreCase`, - -`IgnoreSymbols | IgnoreNonSpace`, - -`IgnoreSymbols | IgnoreNonSpace | IgnoreCase`, - -`IgnoreWidth`, - -`IgnoreWidth | IgnoreCase`, - -`IgnoreWidth | IgnoreNonSpace`, - -`IgnoreWidth | IgnoreNonSpace | IgnoreCase`, - -`IgnoreWidth | IgnoreSymbols` - -`IgnoreWidth | IgnoreSymbols | IgnoreCase` - -`IgnoreWidth | IgnoreSymbols | IgnoreNonSpace` - -`IgnoreWidth | IgnoreSymbols | IgnoreNonSpace | IgnoreCase` - -`IgnoreKanaType | IgnoreWidth` - -`IgnoreKanaType | IgnoreWidth | IgnoreCase` - -`IgnoreKanaType | IgnoreWidth | IgnoreNonSpace` - -`IgnoreKanaType | IgnoreWidth | IgnoreNonSpace | IgnoreCase` - -`IgnoreKanaType | IgnoreWidth | IgnoreSymbols` - -`IgnoreKanaType | IgnoreWidth | IgnoreSymbols | IgnoreCase` - -`IgnoreKanaType | IgnoreWidth | IgnoreSymbols | IgnoreNonSpace` - -`IgnoreKanaType | IgnoreWidth | IgnoreSymbols | IgnoreNonSpace | IgnoreCase` - - -**String starts with / ends with** - -Affected public APIs: -- CompareInfo.IsPrefix -- CompareInfo.IsSuffix -- String.StartsWith -- String.EndsWith - -Dependencies: -- [String.prototype.normalize()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/normalize) -- [String.prototype.localeCompare()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/localeCompare) - -Web API does not expose locale-sensitive endsWith/startsWith function. As a workaround, both strings get normalized and weightless characters are removed. Resulting strings are cut to the same length and comparison is performed. This approach, beyond having the same compare option limitations as described under **String comparison**, has additional limitations connected with the workaround used. Because we are normalizing strings to be able to cut them, we cannot calculate the match length on the original strings. Methods that calculate this information throw PlatformNotSupported exception: - -- [CompareInfo.IsPrefix](https://learn.microsoft.com/dotnet/api/system.globalization.compareinfo.isprefix?view=#system-globalization-compareinfo-isprefix(system-readonlyspan((system-char))-system-readonlyspan((system-char))-system-globalization-compareoptions-system-int32@)) -- [CompareInfo.IsSuffix](https://learn.microsoft.com/dotnet/api/system.globalization.compareinfo.issuffix?view=system-globalization-compareinfo-issuffix(system-readonlyspan((system-char))-system-readonlyspan((system-char))-system-globalization-compareoptions-system-int32@)) - -- `IgnoreSymbols` -Only comparisons that do not skip character types are allowed. E.g. `IgnoreSymbols` skips symbol-chars in comparison/indexing. All `CompareOptions` combinations that include `IgnoreSymbols` throw `PlatformNotSupportedException`. - -**String indexing** - -Affected public APIs: -- CompareInfo.IndexOf -- CompareInfo.LastIndexOf -- String.IndexOf -- String.LastIndexOf - -Web API does not expose locale-sensitive indexing function. There is a discussion on adding it: https://github.com/tc39/ecma402/issues/506. In the current state, as a workaround, locale-sensitive string segmenter combined with locale-sensitive comparison is used. This approach, beyond having the same compare option limitations as described under **String comparison**, has additional limitations connected with the workaround used. Information about additional limitations: - -- Methods that calculate `matchLength` always return throw PlatformNotSupported exception: - -[CompareInfo.IndexOf](https://learn.microsoft.com/en-us/dotnet/api/system.globalization.compareinfo.indexof?view=system-globalization-compareinfo-indexof(system-readonlyspan((system-char))-system-readonlyspan((system-char))-system-globalization-compareoptions-system-int32@)) - -[CompareInfo.LastIndexOf](https://learn.microsoft.com/en-us/dotnet/api/system.globalization.compareinfo.lastindexof?view=system-globalization-compareinfo-lastindexof(system-readonlyspan((system-char))-system-readonlyspan((system-char))-system-globalization-compareoptions-system-int32@)) - -- String.Replace that uses `StringComparison` argument relies internally on IndexOf with `matchLength` argument. From this reason, it throws PlatformNotSupportedException: -[String.Replace](https://learn.microsoft.com/en-us/dotnet/api/system.string.replace?view=system-string-replace(system-string-system-string-system-stringcomparison)) - -- Support depends on [`Intl.segmenter's support`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Segmenter#browser_compatibility). - -- `IgnoreSymbols` - -Only comparisons that ignore types of characters but do not skip them are allowed. E.g. `IgnoreCase` ignores type (case) of characters but `IgnoreSymbols` skips symbol-chars in comparison/indexing. All `CompareOptions` combinations that include `IgnoreSymbols` throw `PlatformNotSupportedException`. - -- Some letters consist of more than one grapheme. - -Using locale-sensitive segmenter `Intl.Segmenter(locale, { granularity: "grapheme" })` does not guarantee that string will be segmented by letters but by graphemes. E.g. in `cs-CZ` and `sk-SK` "ch" is 1 letter, 2 graphemes. The following code with `HybridGlobalization` switched off returns -1 (not found) while with `HybridGlobalization` switched on, it returns 1. - -``` C# -new CultureInfo("sk-SK").CompareInfo.IndexOf("ch", "h"); // -1 or 1 -``` - -- Some graphemes consist of more than one character. -E.g. `\r\n` that represents two characters in C#, is treated as one grapheme by the segmenter: - -``` JS -const segmenter = new Intl.Segmenter(undefined, { granularity: "grapheme" }); -Array.from(segmenter.segment("\r\n")) // {segment: '\r\n', index: 0, input: '\r\n'} -``` - -Because we are comparing grapheme-by-grapheme, character `\r` or character `\n` will not be found in `\r\n` string when `HybridGlobalization` is switched on. - -- Some graphemes have multi-grapheme equivalents. -E.g. in `de-DE` ß (%u00DF) is one letter and one grapheme and "ss" is one letter and is recognized as two graphemes. Web API's equivalent of `IgnoreNonSpace` treats them as the same letter when comparing. Similar case: dz (%u01F3) and dz. -``` JS -"ß".localeCompare("ss", "de-DE", { sensitivity: "case" }); // 0 -``` - -Using `IgnoreNonSpace` for these two with `HybridGlobalization` off, also returns 0 (they are equal). However, the workaround used in `HybridGlobalization` will compare them grapheme-by-grapheme and will return -1. - -``` C# -new CultureInfo("de-DE").CompareInfo.IndexOf("strasse", "stra\u00DFe", 0, CompareOptions.IgnoreNonSpace); // 0 or -1 -``` - -**Calandars** - -Affected public APIs: -- DateTimeFormatInfo.AbbreviatedDayNames -- DateTimeFormatInfo.GetAbbreviatedDayName() -- DateTimeFormatInfo.AbbreviatedMonthGenitiveNames -- DateTimeFormatInfo.AbbreviatedMonthNames -- DateTimeFormatInfo.GetAbbreviatedMonthName() -- DateTimeFormatInfo.AMDesignator -- DateTimeFormatInfo.CalendarWeekRule -- DateTimeFormatInfo.DayNames -- DateTimeFormatInfo.GetDayName -- DateTimeFormatInfo.GetAbbreviatedEraName() -- DateTimeFormatInfo.GetEraName() -- DateTimeFormatInfo.FirstDayOfWeek -- DateTimeFormatInfo.FullDateTimePattern -- DateTimeFormatInfo.LongDatePattern -- DateTimeFormatInfo.LongTimePattern -- DateTimeFormatInfo.MonthDayPattern -- DateTimeFormatInfo.MonthGenitiveNames -- DateTimeFormatInfo.MonthNames -- DateTimeFormatInfo.GetMonthName() -- DateTimeFormatInfo.NativeCalendarName -- DateTimeFormatInfo.PMDesignator -- DateTimeFormatInfo.ShortDatePattern -- DateTimeFormatInfo.ShortestDayNames -- DateTimeFormatInfo.GetShortestDayName() -- DateTimeFormatInfo.ShortTimePattern -- DateTimeFormatInfo.YearMonthPattern - - -The Hybrid responses may differ because they use Web API functions. To better ilustrate the mechanism we provide an example for each endpoint. All exceptions cannot be listed, for reference check the response of specific version of Web API on your host. -| **API** | **Functions used** | **Example of difference for locale** | **non-Hybrid** | **Hybrid** | -|:-----------------------------:|:----------------------------------------------------------------------------------------------------------------------------------:|:------------------------------------:|:------------------:|:-----------------:| -| AbbreviatedDayNames | `Date.prototype.toLocaleDateString(locale, { weekday: "short" })` | en-CA | Sun. | Sun | -| AbbreviatedMonthGenitiveNames | `Date.prototype.toLocaleDateString(locale, { month: "short", day: "numeric"})` | kn-IN | ಆಗ | ಆಗಸ್ಟ್ | -| AbbreviatedMonthNames | `Date.prototype.toLocaleDateString(locale, { month: "short" })` | lt-LT | saus. | 01 | -| AMDesignator | `Date.prototype.toLocaleTimeString(locale, { hourCycle: "h12"})`; `Date.prototype.toLocaleTimeString(locale, { hourCycle: "h24"})` | sr-Cyrl-RS | пре подне | AM | -| CalendarWeekRule | `Intl.Locale.prototype.getWeekInfo().minimalDay` | none | - | - | -| DayNames | `Date.prototype.toLocaleDateString(locale, { weekday: "long" })` | none | - | - | -| GetAbbreviatedEraName() | `Date.prototype.toLocaleDateString(locale, { era: "narrow" })` | bn-IN | খৃষ্টাব্দ | খ্রিঃ | -| GetEraName() | `Date.prototype.toLocaleDateString(locale, { era: "short" })` | vi-VI | sau CN | CN | -| FirstDayOfWeek | `Intl.Locale.prototype.getWeekInfo().firstDay` | zn-CN | Sunday | Monday | -| FullDateTimePattern | `LongDatePattern` and `LongTimePattern` | - | | | -| LongDatePattern | `Intl.DateTimeFormat(locale, { weekday: "long", year: "numeric", month: "long", day: "numeric"}).format(date)` | en-BW | dddd, dd MMMM yyyy | dddd, d MMMM yyyy | -| LongTimePattern | `Intl.DateTimeFormat(locale, { timeStyle: "medium" })` | zn-CN | tth:mm:ss | HH:mm:ss | -| MonthDayPattern | `Date.prototype.toLocaleDateString(locale, { month: "long", day: "numeric"})` | en-PH | d MMMM | MMMM d | -| MonthGenitiveNames | `Date.prototype.toLocaleDateString(locale, { month: "long", day: "numeric"})` | ca-AD | de gener | gener | -| MonthNames | `Date.prototype.toLocaleDateString(locale, { month: "long" })` | el-GR | Ιανουαρίου | Ιανουάριος | -| NativeCalendarName | `Intl.Locale.prototype.getCalendars()` | for all locales it has English names | Gregorian Calendar | gregory | -| PMDesignator | `Date.prototype.toLocaleTimeString(locale, { hourCycle: "h12"})`; `Date.prototype.toLocaleTimeString(locale, { hourCycle: "h24"})` | mr-IN | म.उ. | PM | -| ShortDatePattern | `Date.prototype.toLocaleDateString(locale, {dateStyle: "short"})` | en-CH | dd.MM.yyyy | dd/MM/yyyy | -| ShortestDayNames | `Date.prototype.toLocaleDateString(locale, { weekday: "narrow" })` | none | - | - | -| ShortTimePattern | `Intl.DateTimeFormat(locale, { timeStyle: "medium" })` | bg-BG | HH:mm | H:mm | -| YearMonthPattern | `Date.prototype.toLocaleDateString(locale, { year: "numeric", month: "long" })` | ar-SA | MMMM yyyy | MMMM yyyy g | - ### Apple platforms For Apple platforms (iOS/tvOS/maccatalyst) we are using native apis instead of ICU data. diff --git a/eng/testing/scenarios/BuildWasmAppsJobsList.txt b/eng/testing/scenarios/BuildWasmAppsJobsList.txt index f94f6fbcaa6c1..1f8b21d6eca66 100644 --- a/eng/testing/scenarios/BuildWasmAppsJobsList.txt +++ b/eng/testing/scenarios/BuildWasmAppsJobsList.txt @@ -20,7 +20,6 @@ Wasm.Build.Tests.Blazor.IcuShardingTests Wasm.Build.Tests.Blazor.SignalRClientTests Wasm.Build.Tests.BuildPublishTests Wasm.Build.Tests.ConfigSrcTests -Wasm.Build.Tests.HybridGlobalizationTests Wasm.Build.Tests.IcuShardingTests Wasm.Build.Tests.IcuShardingTests2 Wasm.Build.Tests.IcuTests diff --git a/eng/testing/tests.browser.targets b/eng/testing/tests.browser.targets index 44c7bc6805fa8..e7029f44e2191 100644 --- a/eng/testing/tests.browser.targets +++ b/eng/testing/tests.browser.targets @@ -227,7 +227,6 @@ <_WasmPropertyNames Include="EmccLinkOptimizationFlag" /> <_WasmPropertyNames Include="WasmIncludeFullIcuData" /> <_WasmPropertyNames Include="WasmIcuDataFileName" /> - <_WasmPropertyNames Include="HybridGlobalization" /> diff --git a/eng/testing/tests.wasi.targets b/eng/testing/tests.wasi.targets index 7f981dde513c7..e29f86cbc2aa0 100644 --- a/eng/testing/tests.wasi.targets +++ b/eng/testing/tests.wasi.targets @@ -138,7 +138,6 @@ <_WasmPropertyNames Include="WasiClangLinkOptimizationFlag" /> <_WasmPropertyNames Include="WasmIncludeFullIcuData" /> <_WasmPropertyNames Include="WasmIcuDataFileName" /> - <_WasmPropertyNames Include="HybridGlobalization" /> diff --git a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.cs b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.cs index 23d63a5ab0e70..a37457fda62a5 100644 --- a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.cs +++ b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.cs @@ -389,9 +389,7 @@ public static string GetDistroVersionString() public static bool IsInvariantGlobalization => m_isInvariant.Value; public static bool IsHybridGlobalization => m_isHybrid.Value; - public static bool IsHybridGlobalizationOnBrowser => m_isHybrid.Value && IsBrowser; public static bool IsHybridGlobalizationOnApplePlatform => m_isHybrid.Value && (IsMacCatalyst || IsiOS || IstvOS); - public static bool IsNotHybridGlobalizationOnBrowser => !IsHybridGlobalizationOnBrowser; public static bool IsNotInvariantGlobalization => !IsInvariantGlobalization; public static bool IsNotHybridGlobalization => !IsHybridGlobalization; public static bool IsNotHybridGlobalizationOnApplePlatform => !IsHybridGlobalizationOnApplePlatform; @@ -401,8 +399,6 @@ public static string GetDistroVersionString() // HG on apple platforms implies ICU public static bool IsIcuGlobalization => !IsInvariantGlobalization && (IsHybridGlobalizationOnApplePlatform || ICUVersion > new Version(0, 0, 0, 0)); - - public static bool IsIcuGlobalizationAndNotHybridOnBrowser => IsIcuGlobalization && IsNotHybridGlobalizationOnBrowser; public static bool IsNlsGlobalization => IsNotInvariantGlobalization && !IsIcuGlobalization && !IsHybridGlobalization; public static bool IsSubstAvailable diff --git a/src/libraries/Common/tests/Tests/System/StringTests.cs b/src/libraries/Common/tests/Tests/System/StringTests.cs index 0d904ecb7ef77..caa4383c3ce00 100644 --- a/src/libraries/Common/tests/Tests/System/StringTests.cs +++ b/src/libraries/Common/tests/Tests/System/StringTests.cs @@ -1034,7 +1034,7 @@ public static void CompareToNoMatch_StringComparison() var secondSpan = new ReadOnlySpan(second); Assert.True(0 > firstSpan.CompareTo(secondSpan, StringComparison.Ordinal)); - // On Apple platforms, string comparison is handled by native Apple functions, which apply normalization techniques + // On Apple platforms, string comparison is handled by native Apple functions, which apply normalization techniques // like `precomposedStringWithCanonicalMapping`. This can lead to differences in behavior compared to other platforms. if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { @@ -1315,7 +1315,7 @@ public static void ContainsNoMatch_StringComparison() Assert.False(firstSpan.Contains(secondSpan, StringComparison.OrdinalIgnoreCase)); - // On Apple platforms, string comparison is handled by native Apple functions, which apply normalization techniques + // On Apple platforms, string comparison is handled by native Apple functions, which apply normalization techniques // like `precomposedStringWithCanonicalMapping`. This can lead to differences in behavior compared to other platforms. if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { @@ -3227,8 +3227,7 @@ which ignore the contraction collation weights (defined as 'tertiary' rules) Assert.Equal(PlatformDetection.IsNlsGlobalization ? 0 : -1, source.IndexOf(target)); Assert.Equal(PlatformDetection.IsNlsGlobalization ? 0 : -1, source.IndexOf(target, StringComparison.CurrentCulture)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - Assert.Equal(0, source.IndexOf(target, StringComparison.CurrentCultureIgnoreCase)); + Assert.Equal(0, source.IndexOf(target, StringComparison.CurrentCultureIgnoreCase)); Assert.Equal(-1, source.IndexOf(target, StringComparison.Ordinal)); Assert.Equal(-1, source.IndexOf(target, StringComparison.OrdinalIgnoreCase)); @@ -3236,8 +3235,7 @@ which ignore the contraction collation weights (defined as 'tertiary' rules) Assert.Equal(PlatformDetection.IsNlsGlobalization ? 0 : -1, span.IndexOf(target.AsSpan(), StringComparison.CurrentCulture)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - Assert.Equal(0, span.IndexOf(target.AsSpan(), StringComparison.CurrentCultureIgnoreCase)); + Assert.Equal(0, span.IndexOf(target.AsSpan(), StringComparison.CurrentCultureIgnoreCase)); Assert.Equal(-1, span.IndexOf(target.AsSpan(), StringComparison.Ordinal)); Assert.Equal(-1, span.IndexOf(target.AsSpan(), StringComparison.OrdinalIgnoreCase)); } @@ -5425,7 +5423,6 @@ private static IEnumerable ToLower_Culture_TestData() [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] [ActiveIssue("https://github.com/dotnet/runtime/issues/95338", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnApplePlatform))] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95503", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public static void Test_ToLower_Culture() { foreach (object[] testdata in ToLower_Culture_TestData()) @@ -5943,7 +5940,6 @@ public static IEnumerable ToUpper_Culture_TestData() [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] [ActiveIssue("https://github.com/dotnet/runtime/issues/95338", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnApplePlatform))] [MemberData(nameof(ToUpper_Culture_TestData))] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95503", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public static void Test_ToUpper_Culture(string actual, string expected, CultureInfo culture) { Assert.Equal(expected, actual.ToUpper(culture)); diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/LateBindingTests.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/LateBindingTests.cs index a95f101731dfc..a04e4b0b29333 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/LateBindingTests.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/LateBindingTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.VisualBasic.CompilerServices.Tests { public class LateBindingTests { - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LateCall_TestData))] public void LateCall(object obj, Type objType, string name, object[] args, string[] paramNames, bool[] copyBack, Func getResult, object expected) { @@ -17,14 +17,14 @@ public void LateCall(object obj, Type objType, string name, object[] args, strin Assert.Equal(expected, getResult(obj)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LateGet_TestData))] public void LateGet(object obj, Type objType, string name, object[] args, string[] paramNames, bool[] copyBack, object expected) { Assert.Equal(expected, LateBinding.LateGet(obj, objType, name, args, paramNames, copyBack)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LateSet_TestData))] public void LateSet(object obj, Type objType, string name, object[] args, string[] paramNames, Func getResult, object expected) { @@ -74,14 +74,14 @@ public void LateIndexSet(object obj, object[] args, string[] paramNames, Func(() => LateBinding.LateIndexSet(obj, args, paramNames)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LateIndexSetComplex_TestData))] public void LateIndexSetComplex(object obj, object[] args, string[] paramNames, bool missing, bool valueType) { diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/LikeOperatorTests.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/LikeOperatorTests.cs index 892fbc5c31b5e..1452be5b7fb33 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/LikeOperatorTests.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/LikeOperatorTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.VisualBasic.CompilerServices.Tests { public class LikeOperatorTests { - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LikeObject_TestData))] [MemberData(nameof(LikeString_TestData))] public void LikeObject(object source, object pattern, object expectedBinaryCompare, object expectedTextCompare) @@ -18,7 +18,7 @@ public void LikeObject(object source, object pattern, object expectedBinaryCompa Assert.Equal(expectedTextCompare, LikeOperator.LikeObject(source, pattern, CompareMethod.Text)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LikeString_TestData))] public void LikeString(string source, string pattern, bool expectedBinaryCompare, bool expectedTextCompare) { diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/ObjectTypeTests.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/ObjectTypeTests.cs index d520d69d6cb6f..f1e4b8ac6935f 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/ObjectTypeTests.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/ObjectTypeTests.cs @@ -287,7 +287,7 @@ public static IEnumerable GetObjectValuePrimitive_TestData() // Add more... } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(LikeObj_TestData))] public void LikeObj(object left, object right, object expectedBinaryCompare, object expectedTextCompare) { @@ -323,7 +323,7 @@ public static IEnumerable LikeObj_NullReference_TestData() yield return new object[] { null, "*" }; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(ObjTst_TestData))] public void ObjTst(object x, object y, bool textCompare, object expected) { diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/OperatorsTests.Comparison.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/OperatorsTests.Comparison.cs index 9e300ec063a23..f90fd7d819824 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/OperatorsTests.Comparison.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/OperatorsTests.Comparison.cs @@ -1107,7 +1107,7 @@ public static IEnumerable Compare_InvalidObjects_TestData() yield return new object[] { new object(), new char[] { '8' } }; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1171,7 +1171,7 @@ public class CompareObjectEqual public static string op_Equality(OperatorsTests left, CompareObjectEqual right) => "tcejbomotsuc"; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectGreater_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1235,7 +1235,7 @@ public class CompareObjectGreater public static string op_GreaterThan(OperatorsTests left, CompareObjectGreater right) => "tcejbomotsuc"; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectGreaterEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1298,7 +1298,7 @@ public class CompareObjectGreaterEqual public static string op_GreaterThanOrEqual(OperatorsTests left, CompareObjectGreaterEqual right) => "tcejbomotsuc"; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectLess_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1362,7 +1362,7 @@ public class CompareObjectLess public static string op_LessThan(OperatorsTests left, CompareObjectLess right) => "tcejbomotsuc"; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectLessEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1425,7 +1425,7 @@ public class CompareObjectLessEqual public static string op_LessThanOrEqual(OperatorsTests left, CompareObjectLessEqual right) => "tcejbomotsuc"; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void CompareObjectNotEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1490,7 +1490,7 @@ public class CompareObjectNotEqual } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1554,7 +1554,7 @@ public class ConditionalCompareObjectEqual public static bool op_Equality(OperatorsTests left, ConditionalCompareObjectEqual right) => true; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectGreater_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1618,7 +1618,7 @@ public class ConditionalCompareObjectGreater public static bool op_GreaterThan(OperatorsTests left, ConditionalCompareObjectGreater right) => true; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectGreaterEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1681,7 +1681,7 @@ public class ConditionalCompareObjectGreaterEqual public static bool op_GreaterThanOrEqual(OperatorsTests left, ConditionalCompareObjectGreaterEqual right) => true; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectLess_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1745,7 +1745,7 @@ public class ConditionalCompareObjectLess public static bool op_LessThan(OperatorsTests left, ConditionalCompareObjectLess right) => true; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectLessEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { @@ -1808,7 +1808,7 @@ public class ConditionalCompareObjectLessEqual public static bool op_LessThanOrEqual(OperatorsTests left, ConditionalCompareObjectLessEqual right) => true; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(Compare_Primitives_TestData))] public void ConditionalCompareObjectNotEqual_Invoke_ReturnsExpected(object left, object right, bool greater, bool equal, bool less) { diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/StringTypeTests.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/StringTypeTests.cs index 76d390ea840e6..8d4d2842766d7 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/StringTypeTests.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/StringTypeTests.cs @@ -363,7 +363,7 @@ public void MidStmtStr_ArgumentException(string str, int start, int length, stri Assert.Throws(() => StringType.MidStmtStr(ref str, start, length, insert)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(StrCmp_TestData))] public void StrCmp(string left, string right, int expectedBinaryCompare, int expectedTextCompare) { @@ -388,7 +388,7 @@ public static IEnumerable StrCmp_TestData() yield return new object[] { "abc", "ABC", 32, 0 }; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData(null, null, true, true)] [InlineData("", null, true, true)] [InlineData("", "*", true, true)] diff --git a/src/libraries/Microsoft.VisualBasic.Core/tests/StringsTests.cs b/src/libraries/Microsoft.VisualBasic.Core/tests/StringsTests.cs index 037412ed58275..27967fa777fe1 100644 --- a/src/libraries/Microsoft.VisualBasic.Core/tests/StringsTests.cs +++ b/src/libraries/Microsoft.VisualBasic.Core/tests/StringsTests.cs @@ -431,7 +431,7 @@ public void InStr_BinaryCompare(string string1, string string2, int expected) Assert.Equal(expected, Strings.InStr(1, string1, string2, CompareMethod.Binary)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData("A", "a", 1)] [InlineData("Aa", "a", 1)] public void InStr_TextCompare(string string1, string string2, int expected) @@ -479,7 +479,7 @@ public void InStrRev_BinaryCompare(string stringCheck, string stringMatch, int s Assert.Equal(expected, Strings.InStrRev(stringCheck, stringMatch, start, CompareMethod.Binary)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData("A", "a", 1, 1)] [InlineData("aA", "a", 2, 2)] public void InStrRev_TextCompare(string stringCheck, string stringMatch, int start, int expected) @@ -779,7 +779,7 @@ public void Trim_Valid(string str, string expected) Assert.Equal(expected, Strings.Trim(str)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData("", "", null, 1, -1, CompareMethod.Text, null)] [InlineData("", null, "", 1, -1, CompareMethod.Text, null)] [InlineData("", "", "", 1, -1, CompareMethod.Text, null)] @@ -815,7 +815,7 @@ public void Space(int number, string expected) Assert.Equal(expected, Strings.Space(number)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData(null, null, -1, CompareMethod.Text, new string[] { "" })] [InlineData(null, "", -1, CompareMethod.Text, new string[] { "" })] [InlineData("", null, -1, CompareMethod.Text, new string[] { "" })] @@ -833,14 +833,14 @@ public void Split(string expression, string delimiter, int limit, CompareMethod Assert.Equal(expected, Strings.Split(expression, delimiter, limit, compare)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData("A, B, C", ", ", 0, CompareMethod.Text)] public void Split_IndexOutOfRangeException(string expression, string delimiter, int limit, CompareMethod compare) { Assert.Throws< IndexOutOfRangeException>(() => Strings.Split(expression, delimiter, limit, compare)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [InlineData("a", "a", 0, 0)] [InlineData("a", "b", -1, -1)] [InlineData("b", "a", 1, 1)] diff --git a/src/libraries/System.Collections.NonGeneric/tests/CaseInsensitiveHashCodeProviderTests.cs b/src/libraries/System.Collections.NonGeneric/tests/CaseInsensitiveHashCodeProviderTests.cs index b0f4cc6c9ee3b..ee5087139eb0e 100644 --- a/src/libraries/System.Collections.NonGeneric/tests/CaseInsensitiveHashCodeProviderTests.cs +++ b/src/libraries/System.Collections.NonGeneric/tests/CaseInsensitiveHashCodeProviderTests.cs @@ -97,7 +97,6 @@ public void Ctor_CultureInfo_ChangeCurrentCulture_GetHashCodeCompare(object a, o [Fact] [ActiveIssue("https://github.com/dotnet/runtime/issues/37069", TestPlatforms.Android | TestPlatforms.LinuxBionic)] [ActiveIssue("https://github.com/dotnet/runtime/issues/95338", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnApplePlatform))] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95503", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public void Ctor_CultureInfo_GetHashCodeCompare_TurkishI() { var cultureNames = Helpers.TestCultureNames; diff --git a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataRowComparerTest.cs b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataRowComparerTest.cs index 0e8fb95a74e6d..6d4ddbe9b3f58 100644 --- a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataRowComparerTest.cs +++ b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataRowComparerTest.cs @@ -216,7 +216,7 @@ public void Equals_Rows_Deleted() } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void GetHashCodeWithVersions() { DataSet ds = new DataSet(); diff --git a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataTableExtensionsTest.cs b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataTableExtensionsTest.cs index 7f6d7bb12c0f2..479807057113e 100644 --- a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataTableExtensionsTest.cs +++ b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/DataTableExtensionsTest.cs @@ -75,7 +75,7 @@ public void CopyToDataTableTableArgNoRows() dt.AsEnumerable().CopyToDataTable(dst, LoadOption.PreserveChanges); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void AsEnumerable() { DataSet ds = new DataSet(); diff --git a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/EnumerableRowCollectionTest.cs b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/EnumerableRowCollectionTest.cs index ba292235291e3..a1f0dd6ec13ff 100644 --- a/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/EnumerableRowCollectionTest.cs +++ b/src/libraries/System.Data.Common/tests/System.Data.DataSetExtensions.Tests/Mono/EnumerableRowCollectionTest.cs @@ -41,7 +41,7 @@ public class EnumerableRowCollectionTest { private string _testDataSet = "Mono/testdataset1.xml"; - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void QueryWhere() { var ds = new DataSet(); @@ -68,7 +68,7 @@ where line.Field("Score") > 80 } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void QueryWhereSelect () { var ds = new DataSet (); @@ -89,7 +89,7 @@ where line.Field ("Score") > 80 } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void QueryWhereSelectOrderBy () { var ds = new DataSet (); @@ -119,7 +119,7 @@ orderby line.Field ("ID") } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void QueryWhereSelectOrderByDescending () { var ds = new DataSet (); @@ -149,7 +149,7 @@ orderby line.Field ("ID") descending } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void ThenBy () { var ds = new DataSet (); @@ -179,7 +179,7 @@ orderby line.Field ("Gender"), line.Field ("ID") } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void ThenByDescending () { var ds = new DataSet (); diff --git a/src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XsltArgumentList.cs b/src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XsltArgumentList.cs index 21603113f5cec..71de03fbcabc9 100644 --- a/src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XsltArgumentList.cs +++ b/src/libraries/System.Private.Xml/tests/Xslt/XslCompiledTransformApi/XsltArgumentList.cs @@ -3252,7 +3252,7 @@ public void AddExtObject32(object param, XslInputType xslInputType, ReaderType r [InlineData("sort.xsl", "sort.txt", XslInputType.Navigator, ReaderType.XmlValidatingReader, OutputType.Writer, NavType.XPathDocument)] [InlineData("sort.xsl", "sort.txt", XslInputType.Navigator, ReaderType.XmlValidatingReader, OutputType.TextWriter, NavType.XPathDocument)] - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] public void AddExtObject33(object param0, object param1, XslInputType xslInputType, ReaderType readerType, OutputType outputType, NavType navType) { ExObj obj = new ExObj(0, _output); diff --git a/src/libraries/System.Runtime.Serialization.Json/tests/DataContractJsonSerializer.cs b/src/libraries/System.Runtime.Serialization.Json/tests/DataContractJsonSerializer.cs index 94cc7459d0b9e..5de787c502988 100644 --- a/src/libraries/System.Runtime.Serialization.Json/tests/DataContractJsonSerializer.cs +++ b/src/libraries/System.Runtime.Serialization.Json/tests/DataContractJsonSerializer.cs @@ -2599,7 +2599,7 @@ public static void DCJS_VerifyDateTimeForFormatStringDCJsonSerSetting() Assert.Equal(value, actual); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] [ActiveIssue("https://github.com/dotnet/runtime/issues/60462", TestPlatforms.iOS | TestPlatforms.tvOS)] public static void DCJS_VerifyDateTimeForFormatStringDCJsonSerSettings() { @@ -2660,7 +2660,7 @@ public static void DCJS_VerifyDateTimeForFormatStringDCJsonSerSettings() Assert.True(actual6 == dateTime); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] public static void DCJS_VerifyDateTimeForDateTimeFormat() { var jsonTypes = new JsonTypes(); diff --git a/src/libraries/System.Runtime.Serialization.Schema/tests/System/Runtime/Serialization/Schema/RoundTripTest.cs b/src/libraries/System.Runtime.Serialization.Schema/tests/System/Runtime/Serialization/Schema/RoundTripTest.cs index 8e26f7a0704b8..f1a852b3a510a 100644 --- a/src/libraries/System.Runtime.Serialization.Schema/tests/System/Runtime/Serialization/Schema/RoundTripTest.cs +++ b/src/libraries/System.Runtime.Serialization.Schema/tests/System/Runtime/Serialization/Schema/RoundTripTest.cs @@ -82,7 +82,6 @@ public void RountTripTest() [Fact] [ActiveIssue("https://github.com/dotnet/runtime/issues/73961", typeof(PlatformDetection), nameof(PlatformDetection.IsBuiltWithAggressiveTrimming), nameof(PlatformDetection.IsBrowser))] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95981", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public void RoundTripXmlSerializableWithSpecialAttributesTest() { XsdDataContractExporter exporter = new XsdDataContractExporter(); diff --git a/src/libraries/System.Runtime.Serialization.Xml/tests/DataContractSerializer.cs b/src/libraries/System.Runtime.Serialization.Xml/tests/DataContractSerializer.cs index e63c47b820702..34550236dda8e 100644 --- a/src/libraries/System.Runtime.Serialization.Xml/tests/DataContractSerializer.cs +++ b/src/libraries/System.Runtime.Serialization.Xml/tests/DataContractSerializer.cs @@ -3542,7 +3542,7 @@ public static void DCS_BasicPerSerializerRoundTripAndCompare_SampleTypes() } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public static void DCS_BasicPerSerializerRoundTripAndCompare_DataSet() { diff --git a/src/libraries/System.Runtime/System.Runtime.sln b/src/libraries/System.Runtime/System.Runtime.sln index 3bb4e42789fd3..4af0484c2667c 100644 --- a/src/libraries/System.Runtime/System.Runtime.sln +++ b/src/libraries/System.Runtime/System.Runtime.sln @@ -77,8 +77,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Dynamic.Runtime.Test EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.CalendarsWithConfigSwitch.Tests", "tests\System.Globalization.Calendars.Tests\CalendarTestWithConfigSwitch\System.Globalization.CalendarsWithConfigSwitch.Tests.csproj", "{B73090B8-20CB-4586-A586-B7F37C1A06FF}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.Calendars.Hybrid.WASM.Tests", "tests\System.Globalization.Calendars.Tests\Hybrid\System.Globalization.Calendars.Hybrid.WASM.Tests.csproj", "{4C1F2761-857C-40A4-8CDD-7139380DA4D7}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.Calendars.IOS.Tests", "tests\System.Globalization.Calendars.Tests\Hybrid\System.Globalization.Calendars.IOS.Tests.csproj", "{70441C80-1F14-42F9-8225-A891E3C9A82A}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.Calendars.Tests", "tests\System.Globalization.Calendars.Tests\System.Globalization.Calendars.Tests.csproj", "{EA3FA657-060E-43A3-9CF0-45FCC8E7E5B6}" @@ -91,8 +89,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.Extens EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AppleHybrid.Tests", "tests\System.Globalization.Tests\Hybrid\AppleHybrid.Tests.csproj", "{988AECC5-6EB4-48AB-9467-3FB63619631B}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.Hybrid.WASM.Tests", "tests\System.Globalization.Tests\Hybrid\System.Globalization.Hybrid.WASM.Tests.csproj", "{C5F86889-E147-4424-9165-D2DF453741F2}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Globalization.IOS.Tests", "tests\System.Globalization.Tests\Hybrid\System.Globalization.IOS.Tests.csproj", "{67D9B289-AA6D-4FD8-A99D-F8651A51BE7E}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "IcuAppLocal.Tests", "tests\System.Globalization.Tests\IcuAppLocal\IcuAppLocal.Tests.csproj", "{B6F2F0D5-9275-4F00-A2C3-2048AF0CAF12}" diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/Hybrid/System.Globalization.Calendars.Hybrid.WASM.Tests.csproj b/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/Hybrid/System.Globalization.Calendars.Hybrid.WASM.Tests.csproj deleted file mode 100644 index 9c93e65d291eb..0000000000000 --- a/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/Hybrid/System.Globalization.Calendars.Hybrid.WASM.Tests.csproj +++ /dev/null @@ -1,116 +0,0 @@ - - - $(NetCoreAppCurrent)-browser - true - true - true - - - - WasmTestOnChrome - $(TestArchiveRoot)browseronly/ - $(TestArchiveTestsRoot)$(OSPlatformConfig)/ - $(DefineConstants);TARGET_BROWSER - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/System/Globalization/CalendarTestBase.cs b/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/System/Globalization/CalendarTestBase.cs index 061d07108e526..62e1b36006987 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/System/Globalization/CalendarTestBase.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Calendars.Tests/System/Globalization/CalendarTestBase.cs @@ -429,8 +429,8 @@ public void GetEra_Invalid_ThrowsArgumentOutOfRangeException() Calendar calendar = Calendar; Assert.All(DateTime_TestData(calendar), dt => { - // JapaneseCalendar throws on ICU, but not on NLS or in HybridGlobalization on Browser - if ((calendar is JapaneseCalendar && (PlatformDetection.IsNlsGlobalization || PlatformDetection.IsHybridGlobalizationOnBrowser)) || calendar is HebrewCalendar || calendar is TaiwanLunisolarCalendar || calendar is JapaneseLunisolarCalendar) + // JapaneseCalendar throws on ICU, but not on NLS + if ((calendar is JapaneseCalendar && PlatformDetection.IsNlsGlobalization) || calendar is HebrewCalendar || calendar is TaiwanLunisolarCalendar || calendar is JapaneseLunisolarCalendar) { calendar.GetEra(dt); } diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.Compare.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.Compare.cs index fd20fa33ffbdc..c3e5fd0e586a8 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.Compare.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.Compare.cs @@ -15,20 +15,15 @@ public class CompareInfoCompareTests : CompareInfoTestsBase public static IEnumerable Compare_Kana_TestData() { - // HybridGlobalization does not support IgnoreWidth - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - CompareOptions ignoreKanaIgnoreWidthIgnoreCase = CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase; - yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u3076\u30D9\uFF8E\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u30D0\u30D3\u3076\u30D9\uFF8E\uFF9E", "\u3070\u3073\uFF8C\uFF9E\uFF8D\uFF9E\u307C", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u3060", "\uFF80\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u30C7\u30BF\u30D9\u30B9", "\uFF83\uFF9E\uFF80\uFF8D\uFF9E\uFF7D", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u30C7", "\uFF83\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u30C7\u30BF", "\uFF83\uFF9E\uFF80", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u30C7\u30BF\u30D9", "\uFF83\uFF9E\uFF80\uFF8D\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "\u3067\u30FC\u305F\u3079\u30FC\u3059", "\uFF83\uFF9E\uFF70\uFF80\uFF8D\uFF9E\uFF70\uFF7D", ignoreKanaIgnoreWidthIgnoreCase, 0 }; - } - + CompareOptions ignoreKanaIgnoreWidthIgnoreCase = CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase; + yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u3076\u30D9\uFF8E\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u30D0\u30D3\u3076\u30D9\uFF8E\uFF9E", "\u3070\u3073\uFF8C\uFF9E\uFF8D\uFF9E\u307C", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u3060", "\uFF80\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u30C7\u30BF\u30D9\u30B9", "\uFF83\uFF9E\uFF80\uFF8D\uFF9E\uFF7D", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u30C7", "\uFF83\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u30C7\u30BF", "\uFF83\uFF9E\uFF80", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u30C7\u30BF\u30D9", "\uFF83\uFF9E\uFF80\uFF8D\uFF9E", ignoreKanaIgnoreWidthIgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "\u3067\u30FC\u305F\u3079\u30FC\u3059", "\uFF83\uFF9E\uFF70\uFF80\uFF8D\uFF9E\uFF70\uFF7D", ignoreKanaIgnoreWidthIgnoreCase, 0 }; yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u3076\u30D9\uFF8E\uFF9E", CompareOptions.None, s_expectedHiraganaToKatakanaCompare }; yield return new object[] { s_invariantCompare, "\u3060", "\uFF80\uFF9E", CompareOptions.None, s_expectedHiraganaToKatakanaCompare }; @@ -43,12 +38,6 @@ public static IEnumerable Compare_Kana_TestData() public static IEnumerable Compare_TestData() { - // PlatformDetection.IsHybridGlobalizationOnBrowser does not support IgnoreNonSpace alone, it needs to be with IgnoreKanaType - CompareOptions validIgnoreNonSpaceOption = - PlatformDetection.IsHybridGlobalizationOnBrowser - ? CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreKanaType - : CompareOptions.IgnoreNonSpace; - #region Numeric ordering if (PlatformDetection.IsNumericComparisonSupported) { @@ -84,7 +73,7 @@ public static IEnumerable Compare_TestData() yield return new object[] { s_invariantCompare, "A01", "a1", CompareOptions.NumericOrdering, isNls ? -1 : 1 }; // ICU treats 01 == 1 // With diacritics - yield return new object[] { s_invariantCompare, "1\u00E102", "1a02", CompareOptions.NumericOrdering | validIgnoreNonSpaceOption, 0 }; + yield return new object[] { s_invariantCompare, "1\u00E102", "1a02", CompareOptions.NumericOrdering | CompareOptions.IgnoreNonSpace, 0 }; yield return new object[] { s_invariantCompare, "\u00E11", "a2", CompareOptions.NumericOrdering, -1 }; // Numerical differences have higher precedence yield return new object[] { s_invariantCompare, "\u00E101", "a1", CompareOptions.NumericOrdering, isNls ? -1 : 1 }; // ICU treats 01 == 1 @@ -93,30 +82,21 @@ public static IEnumerable Compare_TestData() } #endregion - // PlatformDetection.IsHybridGlobalizationOnBrowser does not support IgnoreKanaType alone, it needs to be e.g. with IgnoreCase - CompareOptions validIgnoreKanaTypeOption = PlatformDetection.IsHybridGlobalizationOnBrowser ? - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreCase : - CompareOptions.IgnoreKanaType; - yield return new object[] { s_invariantCompare, "\u3042", "\u30A2", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u304D\u3083", "\u30AD\u30E3", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u304D\u3083", "\u30AD\u3083", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u304D \u3083", "\u30AD\u3083", validIgnoreKanaTypeOption, -1 }; - yield return new object[] { s_invariantCompare, "\u3044", "I", validIgnoreKanaTypeOption, 1 }; - yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u30D6\u30D9\u30DC", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u3076\u30D9\u30DC", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u3060", "\u305F", validIgnoreKanaTypeOption, 1 }; - yield return new object[] { s_invariantCompare, "\u3060", "\u30C0", validIgnoreKanaTypeOption, 0 }; - yield return new object[] { s_invariantCompare, "\u68EE\u9D0E\u5916", "\u68EE\u9DD7\u5916", validIgnoreKanaTypeOption, -1 }; - yield return new object[] { s_invariantCompare, "\u2019", "'", validIgnoreKanaTypeOption, 1 }; - yield return new object[] { s_invariantCompare, "", "'", validIgnoreKanaTypeOption, -1 }; + yield return new object[] { s_invariantCompare, "\u3042", "\u30A2", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u304D\u3083", "\u30AD\u30E3", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u304D\u3083", "\u30AD\u3083", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u304D \u3083", "\u30AD\u3083", CompareOptions.IgnoreKanaType, -1 }; + yield return new object[] { s_invariantCompare, "\u3044", "I", CompareOptions.IgnoreKanaType, 1 }; + yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u30D6\u30D9\u30DC", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u3070\u3073\u3076\u3079\u307C", "\u30D0\u30D3\u3076\u30D9\u30DC", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u3060", "\u305F", CompareOptions.IgnoreKanaType, 1 }; + yield return new object[] { s_invariantCompare, "\u3060", "\u30C0", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "\u68EE\u9D0E\u5916", "\u68EE\u9DD7\u5916", CompareOptions.IgnoreKanaType, -1 }; + yield return new object[] { s_invariantCompare, "\u2019", "'", CompareOptions.IgnoreKanaType, 1 }; + yield return new object[] { s_invariantCompare, "", "'", CompareOptions.IgnoreKanaType, -1 }; yield return new object[] { s_invariantCompare, "\u30FC", "\uFF70", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreCase, 0 }; - // PlatformDetection.IsHybridGlobalizationOnBrowser does not support IgnoreWidth - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "\u3042", "\uFF71", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "'\u3000'", "' '", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, PlatformDetection.IsHybridGlobalizationOnApplePlatform ? 1 : 0 }; - } - + yield return new object[] { s_invariantCompare, "\u3042", "\uFF71", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "'\u3000'", "' '", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, PlatformDetection.IsHybridGlobalizationOnApplePlatform ? 1 : 0 }; yield return new object[] { s_invariantCompare, "\u6FA4", "\u6CA2", CompareOptions.None, 1 }; yield return new object[] { s_invariantCompare, "\u3070\u3073\uFF8C\uFF9E\uFF8D\uFF9E\u307C", "\uFF8E\uFF9E", CompareOptions.None, -1 }; yield return new object[] { s_invariantCompare, "\u3070\u30DC\uFF8C\uFF9E\uFF8D\uFF9E\u307C", "\uFF8E\uFF9E", CompareOptions.None, -1 }; @@ -138,25 +118,21 @@ public static IEnumerable Compare_TestData() yield return new object[] { s_invariantCompare, "\u30FC", "\u2010", CompareOptions.None, 1 }; yield return new object[] { s_invariantCompare, "\u68EE\u9DD7\u5916", "\u68EE\u9DD7\u5916", CompareOptions.IgnoreCase, 0 }; yield return new object[] { s_invariantCompare, "a", "A", CompareOptions.IgnoreCase, 0 }; - // PlatformDetection.IsHybridGlobalizationOnBrowser does not support IgnoreWidth - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "a", "\uFF41", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "ABCDE", "\uFF21\uFF22\uFF23\uFF24\uFF25", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "ABCDE", "\uFF21\uFF22\uFF23D\uFF25", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "ABCDE", "a\uFF22\uFF23D\uFF25", CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "ABCDE", "\uFF41\uFF42\uFF23D\uFF25", CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; - yield return new object[] { s_invariantCompare, "ABCDE", "\uFF43D", CompareOptions.IgnoreWidth, -1 }; - yield return new object[] { s_invariantCompare, "ABCDE", "c", CompareOptions.IgnoreWidth, -1 }; - yield return new object[] { s_invariantCompare, "\u30BF", "\uFF80", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "0", "\uFF10", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "10", "1\uFF10", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "\uFF1B", ";", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "\uFF08", "(", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "/", "\uFF0F", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "'", "\uFF07", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "\"", "\uFF02", CompareOptions.IgnoreWidth, 0 }; - } + yield return new object[] { s_invariantCompare, "a", "\uFF41", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "ABCDE", "\uFF21\uFF22\uFF23\uFF24\uFF25", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "ABCDE", "\uFF21\uFF22\uFF23D\uFF25", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "ABCDE", "a\uFF22\uFF23D\uFF25", CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "ABCDE", "\uFF41\uFF42\uFF23D\uFF25", CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, 0 }; + yield return new object[] { s_invariantCompare, "ABCDE", "\uFF43D", CompareOptions.IgnoreWidth, -1 }; + yield return new object[] { s_invariantCompare, "ABCDE", "c", CompareOptions.IgnoreWidth, -1 }; + yield return new object[] { s_invariantCompare, "\u30BF", "\uFF80", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "0", "\uFF10", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "10", "1\uFF10", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "\uFF1B", ";", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "\uFF08", "(", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "/", "\uFF0F", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "'", "\uFF07", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "\"", "\uFF02", CompareOptions.IgnoreWidth, 0 }; yield return new object[] { s_invariantCompare, "\u3042", "\u30A1", CompareOptions.None, PlatformDetection.IsHybridGlobalizationOnApplePlatform ? 1 : s_expectedHiraganaToKatakanaCompare }; yield return new object[] { s_invariantCompare, "\u3042", "\u30A2", CompareOptions.None, s_expectedHiraganaToKatakanaCompare }; yield return new object[] { s_invariantCompare, "\u3042", "\uFF71", CompareOptions.None, s_expectedHiraganaToKatakanaCompare }; @@ -247,7 +223,7 @@ public static IEnumerable Compare_TestData() yield return new object[] { s_invariantCompare, "\u00C0", "a\u0300", CompareOptions.Ordinal, 1 }; yield return new object[] { s_invariantCompare, "\u00C0", "a\u0300", CompareOptions.OrdinalIgnoreCase, 1 }; yield return new object[] { s_invariantCompare, "FooBar", "Foo\u0400Bar", CompareOptions.Ordinal, -1 }; - yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", validIgnoreNonSpaceOption, 0 }; + yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", CompareOptions.IgnoreNonSpace, 0 }; // In HybridGlobalization on Apple platforms IgnoreSymbols is not supported if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) @@ -268,11 +244,11 @@ public static IEnumerable Compare_TestData() yield return new object[] { s_invariantCompare, "", "", CompareOptions.None, 0 }; yield return new object[] { s_invariantCompare, new string('a', 5555), new string('a', 5555), CompareOptions.None, 0 }; - yield return new object[] { s_invariantCompare, "foobar", "FooB\u00C0R", supportedIgnoreCaseIgnoreNonSpaceOptions, 0 }; - yield return new object[] { s_invariantCompare, "foobar", "FooB\u00C0R", validIgnoreNonSpaceOption, -1 }; + yield return new object[] { s_invariantCompare, "foobar", "FooB\u00C0R", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "foobar", "FooB\u00C0R", CompareOptions.IgnoreNonSpace, -1 }; - yield return new object[] { s_invariantCompare, "\uFF9E", "\u3099", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\uFF9E", "\u3099", CompareOptions.IgnoreCase, PlatformDetection.IsHybridGlobalizationOnBrowser ? 1 : 0 }; + yield return new object[] { s_invariantCompare, "\uFF9E", "\u3099", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\uFF9E", "\u3099", CompareOptions.IgnoreCase, 0 }; yield return new object[] { s_invariantCompare, "\u20A9", "\uFFE6", CompareOptions.IgnoreCase, -1 }; yield return new object[] { s_invariantCompare, "\u20A9", "\uFFE6", CompareOptions.None, -1 }; @@ -281,21 +257,13 @@ public static IEnumerable Compare_TestData() { yield return new object[] { s_invariantCompare, "\u0021", "\uFF01", CompareOptions.IgnoreSymbols, 0 }; yield return new object[] { s_invariantCompare, "\uFF65", "\u30FB", CompareOptions.IgnoreSymbols, 0 }; - // some symbols e.g. currencies are not ignored correctly in HybridGlobalization - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "\u00A2", "\uFFE0", CompareOptions.IgnoreSymbols, 0 }; - yield return new object[] { s_invariantCompare, "$", "&", CompareOptions.IgnoreSymbols, 0 }; - } + yield return new object[] { s_invariantCompare, "\u00A2", "\uFFE0", CompareOptions.IgnoreSymbols, 0 }; + yield return new object[] { s_invariantCompare, "$", "&", CompareOptions.IgnoreSymbols, 0 }; } yield return new object[] { s_invariantCompare, "\u0021", "\uFF01", CompareOptions.None, -1 }; - - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "\u20A9", "\uFFE6", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "\u0021", "\uFF01", CompareOptions.IgnoreWidth, 0 }; - yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.IgnoreWidth, 0 }; - } + yield return new object[] { s_invariantCompare, "\u20A9", "\uFFE6", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "\u0021", "\uFF01", CompareOptions.IgnoreWidth, 0 }; + yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.IgnoreWidth, 0 }; // In HybridGlobalization mode on Apple platforms IgnoreSymbols is not supported if(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) @@ -304,16 +272,10 @@ public static IEnumerable Compare_TestData() } yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.IgnoreCase, s_expectedHalfToFullFormsComparison }; - // in HybridGlobalization on Browser IgnoreNonSpace is not supported and comparison of katakana/hiragana equivalents with supportedIgnoreNonSpaceOption gives 0 - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.IgnoreNonSpace, s_expectedHalfToFullFormsComparison }; + yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.IgnoreNonSpace, s_expectedHalfToFullFormsComparison }; yield return new object[] { s_invariantCompare, "\uFF66", "\u30F2", CompareOptions.None, s_expectedHalfToFullFormsComparison }; - - // in HybridGlobalization on Browser IgnoreKanaType is supported only for "ja" - var kanaComparison = PlatformDetection.IsHybridGlobalizationOnBrowser ? s_japaneseCompare : s_invariantCompare; - - yield return new object[] { kanaComparison, "\u3060", "\u30C0", CompareOptions.IgnoreKanaType, 0 }; - yield return new object[] { kanaComparison, "c", "C", CompareOptions.IgnoreKanaType, -1 }; + yield return new object[] { s_invariantCompare, "\u3060", "\u30C0", CompareOptions.IgnoreKanaType, 0 }; + yield return new object[] { s_invariantCompare, "c", "C", CompareOptions.IgnoreKanaType, -1 }; yield return new object[] { s_invariantCompare, "\u3060", "\u30C0", CompareOptions.IgnoreCase, PlatformDetection.IsHybridGlobalizationOnApplePlatform ? 1 : s_expectedHiraganaToKatakanaCompare }; @@ -324,12 +286,12 @@ public static IEnumerable Compare_TestData() yield return new object[] { s_invariantCompare, "\u30CF", "\u30D0", CompareOptions.IgnoreCase, -1 }; yield return new object[] { s_invariantCompare, "\u30CF", "\u30D1", CompareOptions.IgnoreCase, -1 }; yield return new object[] { s_invariantCompare, "\u30D0", "\u30D1", CompareOptions.IgnoreCase, -1 }; - yield return new object[] { s_invariantCompare, "\u306F", "\u3070", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\u306F", "\u3071", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\u3070", "\u3071", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\u30CF", "\u30D0", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\u30CF", "\u30D1", validIgnoreNonSpaceOption, 0 }; - yield return new object[] { s_invariantCompare, "\u30D0", "\u30D1", validIgnoreNonSpaceOption, 0 }; + yield return new object[] { s_invariantCompare, "\u306F", "\u3070", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\u306F", "\u3071", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\u3070", "\u3071", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\u30CF", "\u30D0", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\u30CF", "\u30D1", CompareOptions.IgnoreNonSpace, 0 }; + yield return new object[] { s_invariantCompare, "\u30D0", "\u30D1", CompareOptions.IgnoreNonSpace, 0 }; // Spanish yield return new object[] { new CultureInfo("es-ES").CompareInfo, "llegar", "lugar", CompareOptions.None, -1 }; @@ -337,10 +299,7 @@ public static IEnumerable Compare_TestData() // Misc differences between platforms bool useNls = PlatformDetection.IsNlsGlobalization; - var japaneseCmp = PlatformDetection.IsHybridGlobalizationOnBrowser ? - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreCase : - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase; - + var japaneseCmp = CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase; yield return new object[] { s_invariantCompare, "\u3042", "\u30A1", japaneseCmp, useNls || PlatformDetection.IsHybridGlobalizationOnApplePlatform ? 1: 0 }; yield return new object[] { s_invariantCompare, "'\u3000'", "''", japaneseCmp, useNls ? 1 : -1 }; @@ -376,7 +335,7 @@ public void CompareWithUnassignedChars() { int result = PlatformDetection.IsNlsGlobalization ? 0 : -1; Compare(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.None, result); - Compare(s_invariantCompare, "FooBar", "Foo\uFFFFBar", supportedIgnoreNonSpaceOption, result); + Compare(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.IgnoreNonSpace, result); } [ConditionalTheory(nameof(IsNotWindowsKanaRegressedVersion))] @@ -622,22 +581,7 @@ public void TestIgnoreKanaAndWidthCases() public static IEnumerable Compare_HiraganaAndKatakana_TestData() { - CompareOptions[] optionsPositive = PlatformDetection.IsHybridGlobalizationOnBrowser ? - new[] { - CompareOptions.None, - CompareOptions.IgnoreCase, - CompareOptions.IgnoreSymbols, - CompareOptions.IgnoreSymbols | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreSymbols, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreCase | CompareOptions.IgnoreSymbols, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.Ordinal, - CompareOptions.OrdinalIgnoreCase, - } : PlatformDetection.IsHybridGlobalizationOnApplePlatform ? + CompareOptions[] data = PlatformDetection.IsHybridGlobalizationOnApplePlatform ? new[] { CompareOptions.None, CompareOptions.IgnoreCase, @@ -675,45 +619,21 @@ public static IEnumerable Compare_HiraganaAndKatakana_TestData() CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreNonSpace, CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, }; - CompareOptions[] optionsNegative = PlatformDetection.IsHybridGlobalizationOnBrowser ? - new[] { - CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreWidth, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreCase, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreCase, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace, - CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreSymbols | CompareOptions.IgnoreNonSpace | CompareOptions.IgnoreCase, - } : + CompareOptions[] optionsNegative = Array.Empty(); if (PlatformDetection.IsNumericComparisonSupported) { // Adding NumericOrdering does not affect whether an option set is supported or not - optionsPositive = optionsPositive.Concat(from opt in optionsPositive where opt != CompareOptions.Ordinal && opt != CompareOptions.OrdinalIgnoreCase select opt | CompareOptions.NumericOrdering).ToArray(); - optionsNegative = optionsNegative.Concat(from opt in optionsNegative where opt != CompareOptions.Ordinal && opt != CompareOptions.OrdinalIgnoreCase select opt | CompareOptions.NumericOrdering).ToArray(); + data = data.Concat(from opt in data where opt != CompareOptions.Ordinal && opt != CompareOptions.OrdinalIgnoreCase select opt | CompareOptions.NumericOrdering).ToArray(); } - yield return new object[] { optionsPositive, optionsNegative }; + yield return new object[] { data }; } [Theory] [MemberData(nameof(Compare_HiraganaAndKatakana_TestData))] - public void TestHiraganaAndKatakana(CompareOptions[] optionsPositive, CompareOptions[] optionsNegative) + public void TestHiraganaAndKatakana(CompareOptions[] data) { const char hiraganaStart = '\u3041'; const char hiraganaEnd = '\u3096'; @@ -747,7 +667,7 @@ public void TestHiraganaAndKatakana(CompareOptions[] optionsPositive, CompareOpt { hiraganaList.Add(c); } - foreach (var option in optionsPositive) + foreach (var option in data) { for (int i = 0; i < hiraganaList.Count; i++) { @@ -766,13 +686,6 @@ public void TestHiraganaAndKatakana(CompareOptions[] optionsPositive, CompareOpt } } } - foreach (var option in optionsNegative) - { - char hiraganaChar1 = hiraganaList[0]; - char katakanaChar1 = (char)(hiraganaChar1 + hiraganaToKatakanaOffset); - Assert.Throws( - () => s_invariantCompare.Compare(new string(hiraganaChar1, 1), new string(katakanaChar1, 1), option)); - } } } } diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IndexOf.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IndexOf.cs index 2750a648bb80d..77a972222a4a2 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IndexOf.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IndexOf.cs @@ -33,7 +33,7 @@ public static IEnumerable IndexOf_TestData() yield return new object[] { s_invariantCompare, "foobardzsdzs", "rddzs", 0, 12, CompareOptions.Ordinal, -1, 0 }; // Slovak - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_slovakCompare, "ch", "h", 0, 2, CompareOptions.None, -1, 0 }; // Android has its own ICU, which doesn't work well with slovak @@ -66,23 +66,16 @@ public static IEnumerable IndexOf_TestData() yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", 0, 9, CompareOptions.IgnoreCase, 8, 1 }; yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", 0, 9, CompareOptions.OrdinalIgnoreCase, -1, 0 }; yield return new object[] { s_invariantCompare, "FooBar", "Foo\u0400Bar", 0, 6, CompareOptions.Ordinal, -1, 0 }; - yield return new object[] { s_invariantCompare, "TestFooBA\u0300R", "FooB\u00C0R", 0, 11, supportedIgnoreNonSpaceOption, 4, 7 }; + yield return new object[] { s_invariantCompare, "TestFooBA\u0300R", "FooB\u00C0R", 0, 11, CompareOptions.IgnoreNonSpace, 4, 7 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", 0, 2, CompareOptions.None, -1, 0 }; - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "\r\n", "\n", 0, 2, CompareOptions.None, -1, 0 }; - } - else - { - yield return new object[] { s_invariantCompare, "\r\n", "\n", 0, 2, CompareOptions.None, 1, 1 }; - } + yield return new object[] { s_invariantCompare, "\r\n", "\n", 0, 2, CompareOptions.None, 1, 1 }; // Weightless characters yield return new object[] { s_invariantCompare, "", "\u200d", 0, 0, CompareOptions.None, 0, 0 }; yield return new object[] { s_invariantCompare, "hello", "\u200d", 1, 3, CompareOptions.IgnoreCase, 1, 0 }; // Ignore symbols - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { s_invariantCompare, "More Test's", "Tests", 0, 11, CompareOptions.IgnoreSymbols, 5, 6 }; yield return new object[] { s_invariantCompare, "More Test's", "Tests", 0, 11, CompareOptions.None, -1, 0 }; yield return new object[] { s_invariantCompare, "cbabababdbaba", "ab", 0, 13, CompareOptions.None, 2, 2 }; @@ -126,16 +119,12 @@ public static IEnumerable IndexOf_TestData() yield return new object[] { s_currentCompare, "\u0131", "\u0131", 0, 1, CompareOptions.Ordinal, 0, 1 }; yield return new object[] { s_currentCompare, "\u0130", "\u0131", 0, 1, CompareOptions.Ordinal, -1, 0 }; yield return new object[] { s_currentCompare, "\u0131", "\u0130", 0, 1, CompareOptions.Ordinal, -1, 0 }; - - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "est", "est", 0, 2, CompareOptions.IgnoreCase, 0, 2 }; - yield return new object[] { s_invariantCompare, " est", "est", 0, 3, CompareOptions.IgnoreCase, 1, 2 }; - yield return new object[] { s_invariantCompare, " st", "st", 0, 2, CompareOptions.IgnoreCase, 1, 1 }; - yield return new object[] { s_invariantCompare, "est", "est", 0, 3, CompareOptions.IgnoreCase, 0, 3 }; - yield return new object[] { s_invariantCompare, " est", "est", 0, 4, CompareOptions.IgnoreCase, 1, 3 }; - yield return new object[] { s_invariantCompare, " st", "st", 0, 3, CompareOptions.IgnoreCase, 1, 2 }; - } + yield return new object[] { s_invariantCompare, "est", "est", 0, 2, CompareOptions.IgnoreCase, 0, 2 }; + yield return new object[] { s_invariantCompare, " est", "est", 0, 3, CompareOptions.IgnoreCase, 1, 2 }; + yield return new object[] { s_invariantCompare, " st", "st", 0, 2, CompareOptions.IgnoreCase, 1, 1 }; + yield return new object[] { s_invariantCompare, "est", "est", 0, 3, CompareOptions.IgnoreCase, 0, 3 }; + yield return new object[] { s_invariantCompare, " est", "est", 0, 4, CompareOptions.IgnoreCase, 1, 3 }; + yield return new object[] { s_invariantCompare, " st", "st", 0, 3, CompareOptions.IgnoreCase, 1, 2 }; // Platform differences if (PlatformDetection.IsNlsGlobalization) @@ -148,18 +137,18 @@ public static IEnumerable IndexOf_TestData() } // Inputs where matched length does not equal value string length - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "stra\u00DFe", 0, 23, supportedIgnoreCaseIgnoreNonSpaceOptions, 4, 7 }; - yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Strasse", 0, 21, supportedIgnoreCaseIgnoreNonSpaceOptions, 4, 6 }; + yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "stra\u00DFe", 0, 23, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, 4, 7 }; + yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Strasse", 0, 21, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, 4, 6 }; if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - yield return new object[] { s_invariantCompare, "abcdzxyz", "\u01F3", 0, 8, supportedIgnoreNonSpaceOption, 3, 2 }; - yield return new object[] { s_invariantCompare, "abc\u01F3xyz", "dz", 0, 7, supportedIgnoreNonSpaceOption, 3, 1 }; + yield return new object[] { s_invariantCompare, "abcdzxyz", "\u01F3", 0, 8, CompareOptions.IgnoreNonSpace, 3, 2 }; + yield return new object[] { s_invariantCompare, "abc\u01F3xyz", "dz", 0, 7, CompareOptions.IgnoreNonSpace, 3, 1 }; } } - yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "xtra\u00DFe", 0, 23, supportedIgnoreCaseIgnoreNonSpaceOptions, -1, 0 }; - yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Xtrasse", 0, 21, supportedIgnoreCaseIgnoreNonSpaceOptions, -1, 0 }; + yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "xtra\u00DFe", 0, 23, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, -1, 0 }; + yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Xtrasse", 0, 21, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, -1, 0 }; } public static IEnumerable IndexOf_Aesc_Ligature_TestData() @@ -256,7 +245,7 @@ static void RunSpanIndexOfTest(CompareInfo compareInfo, ReadOnlySpan sourc valueBoundedMemory.MakeReadonly(); Assert.Equal(expected, compareInfo.IndexOf(sourceBoundedMemory.Span, valueBoundedMemory.Span, options)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { Assert.Equal(expected, compareInfo.IndexOf(sourceBoundedMemory.Span, valueBoundedMemory.Span, options, out int actualMatchLength)); Assert.Equal(expectedMatchLength, actualMatchLength); @@ -303,7 +292,7 @@ public void IndexOf_UnassignedUnicode() bool useNls = PlatformDetection.IsNlsGlobalization; int expectedMatchLength = (useNls) ? 6 : 0; IndexOf_String(s_invariantCompare, "FooBar", "Foo\uFFFFBar", 0, 6, CompareOptions.None, useNls ? 0 : -1, expectedMatchLength); - IndexOf_String(s_invariantCompare, "~FooBar", "Foo\uFFFFBar", 0, 7, supportedIgnoreNonSpaceOption, useNls ? 1 : -1, expectedMatchLength); + IndexOf_String(s_invariantCompare, "~FooBar", "Foo\uFFFFBar", 0, 7, CompareOptions.IgnoreNonSpace, useNls ? 1 : -1, expectedMatchLength); } [Fact] @@ -353,7 +342,7 @@ public void IndexOf_Invalid() AssertExtensions.Throws("options", () => s_invariantCompare.IndexOf("Test's", 'c', 0, 2, CompareOptions.NumericOrdering)); AssertExtensions.Throws("options", () => s_invariantCompare.IndexOf("Test's".AsSpan(), "b".AsSpan(), CompareOptions.NumericOrdering)); - if (PlatformDetection.IsHybridGlobalizationOnBrowser || PlatformDetection.IsHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsHybridGlobalizationOnApplePlatform) { Assert.Throws(() => s_invariantCompare.IndexOf("Test's".AsSpan(), "b".AsSpan(), CompareOptions.StringSort, out _)); Assert.Throws(() => s_invariantCompare.IndexOf("Test's".AsSpan(), "b".AsSpan(), CompareOptions.NumericOrdering, out _)); diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsPrefix.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsPrefix.cs index 7dba521344e1c..3fba71b155c17 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsPrefix.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsPrefix.cs @@ -25,7 +25,7 @@ public static IEnumerable IsPrefix_TestData() yield return new object[] { s_invariantCompare, "dzsdzsfoobar", "ddzsf", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_hungarianCompare, "dzsdzsfoobar", "ddzsf", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_invariantCompare, "dz", "d", CompareOptions.None, true, 1 }; - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { s_hungarianCompare, "dz", "d", CompareOptions.None, false, 0 }; yield return new object[] { s_hungarianCompare, "dz", "d", CompareOptions.Ordinal, true, 1 }; @@ -52,7 +52,7 @@ public static IEnumerable IsPrefix_TestData() yield return new object[] { s_invariantCompare, "\u00C0nimal", "a\u0300", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_invariantCompare, "\u00C0nimal", "a\u0300", CompareOptions.OrdinalIgnoreCase, false, 0 }; yield return new object[] { s_invariantCompare, "FooBar", "Foo\u0400Bar", CompareOptions.Ordinal, false, 0 }; - yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", supportedIgnoreNonSpaceOption, true, 7 }; + yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", CompareOptions.IgnoreNonSpace, true, 7 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", CompareOptions.None, false, 0 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", CompareOptions.Ordinal, true, 1 }; yield return new object[] { s_invariantCompare, "o\u0000\u0308", "o", CompareOptions.None, true, 1 }; @@ -72,19 +72,16 @@ public static IEnumerable IsPrefix_TestData() yield return new object[] { s_invariantCompare, "\uD800\uD800", "\uD800\uD800", CompareOptions.None, true, 2 }; // Ignore symbols - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_invariantCompare, "Test's can be interesting", "Tests", CompareOptions.IgnoreSymbols, true, 6 }; yield return new object[] { s_invariantCompare, "Test's can be interesting", "Tests", CompareOptions.None, false, 0 }; } // Platform differences - // in HybridGlobalization on Browser we use TextEncoder that is not supported for v8 and the manual decoding works like NLS - bool behavesLikeNls = PlatformDetection.IsNlsGlobalization || - (PlatformDetection.IsHybridGlobalizationOnBrowser && !PlatformDetection.IsBrowserDomSupportedOrNodeJS); - if (behavesLikeNls) + if (PlatformDetection.IsNlsGlobalization) { - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_hungarianCompare, "dzsdzsfoobar", "ddzsf", CompareOptions.None, true, 7 }; yield return new object[] { s_invariantCompare, "''Tests", "Tests", CompareOptions.IgnoreSymbols, true, 7 }; @@ -96,7 +93,7 @@ public static IEnumerable IsPrefix_TestData() else { yield return new object[] { s_hungarianCompare, "dzsdzsfoobar", "ddzsf", CompareOptions.None, false, 0 }; - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { s_invariantCompare, "''Tests", "Tests", CompareOptions.IgnoreSymbols, false, 0 }; yield return new object[] { s_frenchCompare, "\u0153", "oe", CompareOptions.None, false, 0 }; if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) @@ -114,15 +111,15 @@ public static IEnumerable IsPrefix_TestData() } // Prefixes where matched length does not equal value string length - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - yield return new object[] { s_invariantCompare, "dzxyz", "\u01F3", supportedIgnoreNonSpaceOption, true, 2 }; - yield return new object[] { s_invariantCompare, "\u01F3xyz", "dz", supportedIgnoreNonSpaceOption, true, 1 }; - yield return new object[] { s_germanCompare, "Strasse xyz", "stra\u00DFe", supportedIgnoreCaseIgnoreNonSpaceOptions, true, 7 }; - yield return new object[] { s_germanCompare, "stra\u00DFe xyz", "Strasse", supportedIgnoreCaseIgnoreNonSpaceOptions, true, 6 }; + yield return new object[] { s_invariantCompare, "dzxyz", "\u01F3", CompareOptions.IgnoreNonSpace, true, 2 }; + yield return new object[] { s_invariantCompare, "\u01F3xyz", "dz", CompareOptions.IgnoreNonSpace, true, 1 }; + yield return new object[] { s_germanCompare, "Strasse xyz", "stra\u00DFe", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, true, 7 }; + yield return new object[] { s_germanCompare, "stra\u00DFe xyz", "Strasse", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, true, 6 }; } - yield return new object[] { s_germanCompare, "Strasse xyz", "xtra\u00DFe", supportedIgnoreCaseIgnoreNonSpaceOptions, false, 0 }; - yield return new object[] { s_germanCompare, "stra\u00DFe xyz", "Xtrasse", supportedIgnoreCaseIgnoreNonSpaceOptions, false, 0 }; + yield return new object[] { s_germanCompare, "Strasse xyz", "xtra\u00DFe", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, false, 0 }; + yield return new object[] { s_germanCompare, "stra\u00DFe xyz", "Xtrasse", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, false, 0 }; } [Theory] @@ -151,7 +148,7 @@ public void IsPrefix(CompareInfo compareInfo, string source, string value, Compa valueBoundedMemory.MakeReadonly(); Assert.Equal(expected, compareInfo.IsPrefix(sourceBoundedMemory.Span, valueBoundedMemory.Span, options)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { Assert.Equal(expected, compareInfo.IsPrefix(sourceBoundedMemory.Span, valueBoundedMemory.Span, options, out int actualMatchLength)); Assert.Equal(expectedMatchLength, actualMatchLength); @@ -164,7 +161,7 @@ public void IsPrefix_UnassignedUnicode() bool result = PlatformDetection.IsNlsGlobalization ? true : false; int expectedMatchLength = (result) ? 6 : 0; IsPrefix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.None, result, expectedMatchLength); - IsPrefix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", supportedIgnoreNonSpaceOption, result, expectedMatchLength); + IsPrefix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.IgnoreNonSpace, result, expectedMatchLength); } [Fact] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsSuffix.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsSuffix.cs index e2506d7fdd84b..d545be88e6747 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsSuffix.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.IsSuffix.cs @@ -25,12 +25,12 @@ public static IEnumerable IsSuffix_TestData() yield return new object[] { s_invariantCompare, "foobardzsdzs", "rddzs", CompareOptions.None, false, 0 }; yield return new object[] { s_invariantCompare, "foobardzsdzs", "rddzs", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_invariantCompare, "dz", "z", CompareOptions.None, true, 1 }; - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { s_hungarianCompare, "dz", "z", CompareOptions.None, false, 0 }; yield return new object[] { s_hungarianCompare, "dz", "z", CompareOptions.Ordinal, true, 1 }; // Slovak - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_slovakCompare, "ch", "h", CompareOptions.None, false, 0 }; yield return new object[] { s_slovakCompare, "velmi chora", "hora", CompareOptions.None, false, 0 }; @@ -59,7 +59,7 @@ public static IEnumerable IsSuffix_TestData() yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", CompareOptions.OrdinalIgnoreCase, false, 0 }; yield return new object[] { s_invariantCompare, "FooBar", "Foo\u0400Bar", CompareOptions.Ordinal, false, 0 }; - yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", supportedIgnoreNonSpaceOption, true, 7 }; + yield return new object[] { s_invariantCompare, "FooBA\u0300R", "FooB\u00C0R", CompareOptions.IgnoreNonSpace, true, 7 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", CompareOptions.None, false, 0 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", CompareOptions.Ordinal, false, 0 }; yield return new object[] { s_invariantCompare, "o\u0308o", "o", CompareOptions.None, true, 1 }; @@ -80,7 +80,7 @@ public static IEnumerable IsSuffix_TestData() yield return new object[] { s_invariantCompare, "\uD800\uD800", "\uD800\uD800", CompareOptions.None, true, 2 }; // Ignore symbols - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_invariantCompare, "More Test's", "Tests", CompareOptions.IgnoreSymbols, true, 6 }; yield return new object[] { s_invariantCompare, "More Test's", "Tests", CompareOptions.None, false, 0 }; @@ -91,16 +91,10 @@ public static IEnumerable IsSuffix_TestData() yield return new object[] { s_invariantCompare, "a\u0000b", "b\u0000b", CompareOptions.None, false, 0 }; // Platform differences - // in HybridGlobalization on Browser we use TextEncoder that is not supported for v8 and the manual decoding works like NLS - bool behavesLikeNls = PlatformDetection.IsNlsGlobalization || - (PlatformDetection.IsHybridGlobalizationOnBrowser && !PlatformDetection.IsBrowserDomSupportedOrNodeJS); - if (behavesLikeNls) + if (PlatformDetection.IsNlsGlobalization) { - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_hungarianCompare, "foobardzsdzs", "rddzs", CompareOptions.None, true, 7 }; - yield return new object[] { s_frenchCompare, "\u0153", "oe", CompareOptions.None, true, 1 }; - } + yield return new object[] { s_hungarianCompare, "foobardzsdzs", "rddzs", CompareOptions.None, true, 7 }; + yield return new object[] { s_frenchCompare, "\u0153", "oe", CompareOptions.None, true, 1 }; yield return new object[] { s_invariantCompare, "\uD800\uDC00", "\uDC00", CompareOptions.None, true, 1 }; yield return new object[] { s_invariantCompare, "\uD800\uDC00", "\uDC00", CompareOptions.IgnoreCase, true, 1 }; } else @@ -115,15 +109,15 @@ public static IEnumerable IsSuffix_TestData() } // Suffixes where matched length does not equal value string length - yield return new object[] { s_germanCompare, "xyz Strasse", "xtra\u00DFe", supportedIgnoreCaseIgnoreNonSpaceOptions, false, 0 }; - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + yield return new object[] { s_germanCompare, "xyz Strasse", "xtra\u00DFe", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, false, 0 }; + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - yield return new object[] { s_invariantCompare, "xyzdz", "\u01F3", supportedIgnoreNonSpaceOption, true, 2 }; - yield return new object[] { s_invariantCompare, "xyz\u01F3", "dz", supportedIgnoreNonSpaceOption, true, 1 }; - yield return new object[] { s_germanCompare, "xyz stra\u00DFe", "Strasse", supportedIgnoreCaseIgnoreNonSpaceOptions, true, 6 }; - yield return new object[] { s_germanCompare, "xyz Strasse", "stra\u00DFe", supportedIgnoreCaseIgnoreNonSpaceOptions, true, 7 }; + yield return new object[] { s_invariantCompare, "xyzdz", "\u01F3", CompareOptions.IgnoreNonSpace, true, 2 }; + yield return new object[] { s_invariantCompare, "xyz\u01F3", "dz", CompareOptions.IgnoreNonSpace, true, 1 }; + yield return new object[] { s_germanCompare, "xyz stra\u00DFe", "Strasse", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, true, 6 }; + yield return new object[] { s_germanCompare, "xyz Strasse", "stra\u00DFe", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, true, 7 }; } - yield return new object[] { s_germanCompare, "xyz stra\u00DFe", "Xtrasse", supportedIgnoreCaseIgnoreNonSpaceOptions, false, 0 }; + yield return new object[] { s_germanCompare, "xyz stra\u00DFe", "Xtrasse", CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, false, 0 }; } [Theory] @@ -152,7 +146,7 @@ public void IsSuffix(CompareInfo compareInfo, string source, string value, Compa valueBoundedMemory.MakeReadonly(); Assert.Equal(expected, compareInfo.IsSuffix(sourceBoundedMemory.Span, valueBoundedMemory.Span, options)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { Assert.Equal(expected, compareInfo.IsSuffix(sourceBoundedMemory.Span, valueBoundedMemory.Span, options, out int actualMatchLength)); Assert.Equal(expectedMatchLength, actualMatchLength); @@ -166,7 +160,7 @@ public void IsSuffix_UnassignedUnicode() int expectedMatchLength = (result) ? 6 : 0; IsSuffix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.None, result, expectedMatchLength); - IsSuffix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", supportedIgnoreNonSpaceOption, result, expectedMatchLength); + IsSuffix(s_invariantCompare, "FooBar", "Foo\uFFFFBar", CompareOptions.IgnoreNonSpace, result, expectedMatchLength); } [Fact] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.LastIndexOf.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.LastIndexOf.cs index 380610e4412b2..da76d1c08810e 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.LastIndexOf.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.LastIndexOf.cs @@ -49,12 +49,10 @@ public static IEnumerable LastIndexOf_TestData() // Slovak yield return new object[] { s_slovakCompare, "ch", "h", 0, 1, CompareOptions.None, -1, 0 }; // Android has its own ICU, which doesn't work well with slovak - if (!PlatformDetection.IsAndroid && !PlatformDetection.IsLinuxBionic && !PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (!PlatformDetection.IsAndroid && !PlatformDetection.IsLinuxBionic && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { yield return new object[] { s_slovakCompare, "hore chodit", "HO", 11, 12, CompareOptions.IgnoreCase, 0, 2 }; - } - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - yield return new object[] { s_slovakCompare, "chh", "h", 2, 2, CompareOptions.None, 2, 1 }; + }yield return new object[] { s_slovakCompare, "chh", "h", 2, 2, CompareOptions.None, 2, 1 }; // Turkish // Android has its own ICU, which doesn't work well with tr @@ -79,16 +77,9 @@ public static IEnumerable LastIndexOf_TestData() yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", 8, 9, CompareOptions.OrdinalIgnoreCase, -1, 0 }; yield return new object[] { s_invariantCompare, "Exhibit \u00C0", "a\u0300", 8, 9, CompareOptions.Ordinal, -1, 0 }; yield return new object[] { s_invariantCompare, "FooBar", "Foo\u0400Bar", 5, 6, CompareOptions.Ordinal, -1, 0 }; - yield return new object[] { s_invariantCompare, "TestFooBA\u0300R", "FooB\u00C0R", 10, 11, supportedIgnoreNonSpaceOption, 4, 7 }; + yield return new object[] { s_invariantCompare, "TestFooBA\u0300R", "FooB\u00C0R", 10, 11, CompareOptions.IgnoreNonSpace, 4, 7 }; yield return new object[] { s_invariantCompare, "o\u0308", "o", 1, 2, CompareOptions.None, -1, 0 }; - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { s_invariantCompare, "\r\n", "\n", 1, 2, CompareOptions.None, -1, 0 }; - } - else - { - yield return new object[] { s_invariantCompare, "\r\n", "\n", 1, 1, CompareOptions.None, 1, 1 }; - } + yield return new object[] { s_invariantCompare, "\r\n", "\n", 1, 1, CompareOptions.None, 1, 1 }; // Weightless characters // NLS matches weightless characters at the end of the string @@ -104,7 +95,7 @@ public static IEnumerable LastIndexOf_TestData() yield return new object[] { s_invariantCompare, "AA\u200DA", "\u200d", 3, 4, CompareOptions.None, 4, 0}; // Ignore symbols - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { s_invariantCompare, "More Test's", "Tests", 10, 11, CompareOptions.IgnoreSymbols, 5, 6 }; yield return new object[] { s_invariantCompare, "More Test's", "Tests", 10, 11, CompareOptions.None, -1, 0 }; yield return new object[] { s_invariantCompare, "cbabababdbaba", "ab", 12, 13, CompareOptions.None, 10, 2 }; @@ -120,15 +111,15 @@ public static IEnumerable LastIndexOf_TestData() } // Inputs where matched length does not equal value string length - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "stra\u00DFe", 22, 23, supportedIgnoreCaseIgnoreNonSpaceOptions, 12, 7 }; - yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Strasse", 20, 21, supportedIgnoreCaseIgnoreNonSpaceOptions, 11, 6 }; - yield return new object[] { s_invariantCompare, "abcdzxyz", "\u01F3", 7, 8, supportedIgnoreNonSpaceOption, 3, 2 }; - yield return new object[] { s_invariantCompare, "abc\u01F3xyz", "dz", 6, 7, supportedIgnoreNonSpaceOption, 3, 1 }; + yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "stra\u00DFe", 22, 23, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, 12, 7 }; + yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Strasse", 20, 21, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, 11, 6 }; + yield return new object[] { s_invariantCompare, "abcdzxyz", "\u01F3", 7, 8, CompareOptions.IgnoreNonSpace, 3, 2 }; + yield return new object[] { s_invariantCompare, "abc\u01F3xyz", "dz", 6, 7, CompareOptions.IgnoreNonSpace, 3, 1 }; } - yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "xtra\u00DFe", 22, 23, supportedIgnoreCaseIgnoreNonSpaceOptions, -1, 0 }; - yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Xtrasse", 20, 21, supportedIgnoreCaseIgnoreNonSpaceOptions, -1, 0 }; + yield return new object[] { s_germanCompare, "abc Strasse Strasse xyz", "xtra\u00DFe", 22, 23, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, -1, 0 }; + yield return new object[] { s_germanCompare, "abc stra\u00DFe stra\u00DFe xyz", "Xtrasse", 20, 21, CompareOptions.IgnoreCase | CompareOptions.IgnoreNonSpace, -1, 0 }; } public static IEnumerable LastIndexOf_Aesc_Ligature_TestData() @@ -253,7 +244,7 @@ static void RunSpanLastIndexOfTest(CompareInfo compareInfo, ReadOnlySpan s valueBoundedMemory.MakeReadonly(); Assert.Equal(expected, compareInfo.LastIndexOf(sourceBoundedMemory.Span, valueBoundedMemory.Span, options)); - if (!PlatformDetection.IsHybridGlobalizationOnBrowser && PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { Assert.Equal(expected, compareInfo.LastIndexOf(sourceBoundedMemory.Span, valueBoundedMemory.Span, options, out int actualMatchLength)); Assert.Equal(expectedMatchLength, actualMatchLength); @@ -307,7 +298,7 @@ public void LastIndexOf_UnassignedUnicode() bool useNls = PlatformDetection.IsNlsGlobalization; int expectedMatchLength = (useNls) ? 6 : 0; LastIndexOf_String(s_invariantCompare, "FooBar", "Foo\uFFFFBar", 5, 6, CompareOptions.None, useNls ? 0 : -1, expectedMatchLength); - LastIndexOf_String(s_invariantCompare, "~FooBar", "Foo\uFFFFBar", 6, 7, supportedIgnoreNonSpaceOption, useNls ? 1 : -1, expectedMatchLength); + LastIndexOf_String(s_invariantCompare, "~FooBar", "Foo\uFFFFBar", 6, 7, CompareOptions.IgnoreNonSpace, useNls ? 1 : -1, expectedMatchLength); } [Fact] @@ -357,7 +348,7 @@ public void LastIndexOf_Invalid() AssertExtensions.Throws("options", () => s_invariantCompare.LastIndexOf("Test's", 'a', 0, 1, CompareOptions.NumericOrdering)); AssertExtensions.Throws("options", () => s_invariantCompare.LastIndexOf("Test's", "a".AsSpan(), CompareOptions.NumericOrdering)); - if (PlatformDetection.IsHybridGlobalizationOnBrowser || PlatformDetection.IsHybridGlobalizationOnApplePlatform) + if (PlatformDetection.IsHybridGlobalizationOnApplePlatform) { Assert.Throws(() => s_invariantCompare.LastIndexOf("Test's", "a".AsSpan(), CompareOptions.StringSort, out int matchLength)); Assert.Throws(() => s_invariantCompare.LastIndexOf("Test's", "a".AsSpan(), CompareOptions.NumericOrdering, out int matchLength)); diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.SortKey.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.SortKey.cs index 193b55baf47b5..51533fa455254 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.SortKey.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CompareInfo/CompareInfoTests.SortKey.cs @@ -272,14 +272,14 @@ public static IEnumerable SortKey_Kana_TestData() yield return new object[] { s_invariantCompare, "\u3060", "\uFF80\uFF9E", CompareOptions.None, s_expectedHiraganaToKatakanaCompare }; } - [ConditionalTheory(typeof(CompareInfoSortKeyTests), nameof(IsNotWindowsKanaRegressedVersionAndNotHybridGlobalizationOnWasm))] + [ConditionalTheory(typeof(CompareInfoSortKeyTests), nameof(IsNotWindowsKanaRegressedVersion))] [MemberData(nameof(SortKey_Kana_TestData))] public void SortKeyKanaTest(CompareInfo compareInfo, string string1, string string2, CompareOptions options, int expected) { SortKeyTest(compareInfo, string1, string2, options, expected); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Theory] [MemberData(nameof(SortKey_TestData))] public void SortKeyTest(CompareInfo compareInfo, string string1, string string2, CompareOptions options, int expectedSign) { @@ -328,7 +328,7 @@ unsafe static void RunSpanSortKeyTest(CompareInfo compareInfo, ReadOnlySpan !PlatformDetection.IsWindows10Version1903OrGreater || PlatformDetection.IsIcuGlobalization || s_invariantCompare.Compare("\u3060", "\uFF80\uFF9E", CompareOptions.IgnoreKanaType | CompareOptions.IgnoreWidth | CompareOptions.IgnoreCase) == 0; - protected static bool IsNotWindowsKanaRegressedVersionAndNotHybridGlobalizationOnWasm() => !PlatformDetection.IsHybridGlobalizationOnBrowser && IsNotWindowsKanaRegressedVersion(); - public class CustomComparer : StringComparer { private readonly CompareInfo _compareInfo; diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CultureInfo/CultureInfoCtor.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CultureInfo/CultureInfoCtor.cs index 9a9523784716c..e5fd8c7fd0a12 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/CultureInfo/CultureInfoCtor.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/CultureInfo/CultureInfoCtor.cs @@ -446,7 +446,7 @@ public void TestCreationWithTemporaryLCID(int lcid) [InlineData("de-DE-u-co-phonebk-t-xx", "de-DE-t-xx", "de-DE-t-xx_phoneboo")] [InlineData("de-DE-u-co-phonebk-t-xx-u-yy", "de-DE-t-xx-u-yy", "de-DE-t-xx-u-yy_phoneboo")] [InlineData("de-DE", "de-DE", "de-DE")] - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] public void TestCreationWithMangledSortName(string cultureName, string expectedCultureName, string expectedSortName) { CultureInfo ci = CultureInfo.GetCultureInfo(cultureName); @@ -461,7 +461,7 @@ public void TestCreationWithMangledSortName(string cultureName, string expectedC [InlineData("qps-plocm", "qps-PLOCM")] // ICU normalize this name to "qps--plocm" which we normalize it back to "qps-plocm" [InlineData("zh_CN", "zh_cn")] [InlineData("km_KH", "km_kh")] - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser), nameof(PlatformDetection.IsNotWindowsServerCore))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform), nameof(PlatformDetection.IsNotWindowsServerCore))] public void TestCreationWithICUNormalizedNames(string cultureName, string expectedCultureName) { CultureInfo ci = CultureInfo.GetCultureInfo(cultureName); diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAMDesignator.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAMDesignator.cs index 927c88c5bcb4d..1e8a615d3c266 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAMDesignator.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAMDesignator.cs @@ -14,207 +14,6 @@ public void AMDesignator_GetInvariantInfo_ReturnsExpected() Assert.Equal("AM", DateTimeFormatInfo.InvariantInfo.AMDesignator); } - public static IEnumerable AMDesignator_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", "ص" }; - yield return new object[] { "am-ET", "ጥዋት" }; - yield return new object[] { "bg-BG", "пр.об." }; - yield return new object[] { "bn-BD", "AM" }; - yield return new object[] { "bn-IN", "AM" }; - yield return new object[] { "ca-AD", "a.\u00A0m." }; - yield return new object[] { "ca-ES", "a.\u00A0m." }; - yield return new object[] { "cs-CZ", "dop." }; - yield return new object[] { "da-DK", "AM" }; - yield return new object[] { "de-AT", "AM" }; - yield return new object[] { "de-BE", "AM" }; - yield return new object[] { "de-CH", "AM" }; - yield return new object[] { "de-DE", "AM" }; - yield return new object[] { "de-IT", "AM" }; - yield return new object[] { "de-LI", "AM" }; - yield return new object[] { "de-LU", "AM" }; - yield return new object[] { "el-CY", "π.μ." }; - yield return new object[] { "el-GR", "π.μ." }; - yield return new object[] { "en-AE", "AM" }; - yield return new object[] { "en-AG", "am" }; - yield return new object[] { "en-AI", "am" }; - yield return new object[] { "en-AS", "AM" }; - yield return new object[] { "en-AT", "am" }; - yield return new object[] { "en-AU", "am" }; - yield return new object[] { "en-BB", "am" }; - yield return new object[] { "en-BE", "am" }; - yield return new object[] { "en-BI", "AM" }; - yield return new object[] { "en-BM", "am" }; - yield return new object[] { "en-BS", "am" }; - yield return new object[] { "en-BW", "am" }; - yield return new object[] { "en-BZ", "am" }; - yield return new object[] { "en-CA", "a.m." }; - yield return new object[] { "en-CC", "am" }; - yield return new object[] { "en-CH", "am" }; - yield return new object[] { "en-CK", "am" }; - yield return new object[] { "en-CM", "am" }; - yield return new object[] { "en-CX", "am" }; - yield return new object[] { "en-CY", "am" }; - yield return new object[] { "en-DE", "am" }; - yield return new object[] { "en-DK", "am" }; - yield return new object[] { "en-DM", "am" }; - yield return new object[] { "en-ER", "am" }; - yield return new object[] { "en-FI", "am" }; - yield return new object[] { "en-FJ", "am" }; - yield return new object[] { "en-FK", "am" }; - yield return new object[] { "en-FM", "am" }; - yield return new object[] { "en-GB", "am" }; - yield return new object[] { "en-GD", "am" }; - yield return new object[] { "en-GG", "am" }; - yield return new object[] { "en-GH", "am" }; - yield return new object[] { "en-GI", "am" }; - yield return new object[] { "en-GM", "am" }; - yield return new object[] { "en-GU", "AM" }; - yield return new object[] { "en-GY", "am" }; - yield return new object[] { "en-HK", "am" }; - yield return new object[] { "en-IE", "a.m." }; - yield return new object[] { "en-IL", "am" }; - yield return new object[] { "en-IM", "am" }; - yield return new object[] { "en-IN", "am" }; - yield return new object[] { "en-IO", "am" }; - yield return new object[] { "en-JE", "am" }; - yield return new object[] { "en-JM", "am" }; - yield return new object[] { "en-KE", "am" }; - yield return new object[] { "en-KI", "am" }; - yield return new object[] { "en-KN", "am" }; - yield return new object[] { "en-KY", "am" }; - yield return new object[] { "en-LC", "am" }; - yield return new object[] { "en-LR", "am" }; - yield return new object[] { "en-LS", "am" }; - yield return new object[] { "en-MG", "am" }; - yield return new object[] { "en-MH", "AM" }; - yield return new object[] { "en-MO", "am" }; - yield return new object[] { "en-MP", "AM" }; - yield return new object[] { "en-MS", "am" }; - yield return new object[] { "en-MT", "am" }; - yield return new object[] { "en-MU", "am" }; - yield return new object[] { "en-MW", "am" }; - yield return new object[] { "en-MY", "am" }; - yield return new object[] { "en-NA", "am" }; - yield return new object[] { "en-NF", "am" }; - yield return new object[] { "en-NG", "am" }; - yield return new object[] { "en-NL", "am" }; - yield return new object[] { "en-NR", "am" }; - yield return new object[] { "en-NU", "am" }; - yield return new object[] { "en-NZ", "am" }; - yield return new object[] { "en-PG", "am" }; - yield return new object[] { "en-PH", "AM" }; // am - yield return new object[] { "en-PK", "am" }; - yield return new object[] { "en-PN", "am" }; - yield return new object[] { "en-PR", "AM" }; - yield return new object[] { "en-PW", "am" }; - yield return new object[] { "en-RW", "am" }; - yield return new object[] { "en-SB", "am" }; - yield return new object[] { "en-SC", "am" }; - yield return new object[] { "en-SD", "am" }; - yield return new object[] { "en-SE", "am" }; - yield return new object[] { "en-SG", "am" }; - yield return new object[] { "en-SH", "am" }; - yield return new object[] { "en-SI", "am" }; - yield return new object[] { "en-SL", "am" }; - yield return new object[] { "en-SS", "am" }; - yield return new object[] { "en-SX", "am" }; - yield return new object[] { "en-SZ", "am" }; - yield return new object[] { "en-TC", "am" }; - yield return new object[] { "en-TK", "am" }; - yield return new object[] { "en-TO", "am" }; - yield return new object[] { "en-TT", "am" }; - yield return new object[] { "en-TV", "am" }; - yield return new object[] { "en-TZ", "am" }; - yield return new object[] { "en-UG", "am" }; - yield return new object[] { "en-UM", "AM" }; - yield return new object[] { "en-US", "AM" }; - yield return new object[] { "en-VC", "am" }; - yield return new object[] { "en-VG", "am" }; - yield return new object[] { "en-VI", "AM" }; - yield return new object[] { "en-VU", "am" }; - yield return new object[] { "en-WS", "am" }; - yield return new object[] { "en-ZA", "am" }; - yield return new object[] { "en-ZM", "am" }; - yield return new object[] { "en-ZW", "am" }; - string latinAmericaSpanishAMDesignator = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "a.\u00A0m." : "a.m."; - yield return new object[] { "es-419", latinAmericaSpanishAMDesignator }; - yield return new object[] { "es-ES", "a.\u00A0m." }; - yield return new object[] { "es-MX", latinAmericaSpanishAMDesignator }; - yield return new object[] { "et-EE", "AM" }; - yield return new object[] { "fa-IR", "قبل‌ازظهر" }; - yield return new object[] { "fi-FI", "ap." }; - yield return new object[] { "fil-PH", "AM" }; - yield return new object[] { "fr-BE", "AM" }; - yield return new object[] { "fr-CA", "a.m." }; - yield return new object[] { "fr-CH", "AM" }; - yield return new object[] { "fr-FR", "AM" }; - yield return new object[] { "gu-IN", "AM" }; - yield return new object[] { "he-IL", "לפנה״צ" }; - yield return new object[] { "hi-IN", "am" }; - yield return new object[] { "hr-BA", "AM" }; - yield return new object[] { "hr-HR", "AM" }; - yield return new object[] { "hu-HU", "de." }; - yield return new object[] { "id-ID", "AM" }; - yield return new object[] { "it-CH", "AM" }; - yield return new object[] { "it-IT", "AM" }; - yield return new object[] { "ja-JP", "午前" }; - yield return new object[] { "kn-IN", "ಪೂರ್ವಾಹ್ನ" }; - yield return new object[] { "ko-KR", "오전" }; - yield return new object[] { "lt-LT", "priešpiet" }; - yield return new object[] { "lv-LV", "priekšpusdienā" }; - yield return new object[] { "ml-IN", "AM" }; - yield return new object[] { "mr-IN", "AM" }; // म.पू. - yield return new object[] { "ms-BN", "PG" }; - yield return new object[] { "ms-MY", "PG" }; - yield return new object[] { "ms-SG", "PG" }; - yield return new object[] { "nb-NO", "a.m." }; - yield return new object[] { "no", "a.m." }; - yield return new object[] { "no-NO", "a.m." }; - yield return new object[] { "nl-AW", "a.m." }; - yield return new object[] { "nl-BE", "a.m." }; - yield return new object[] { "nl-NL", "a.m." }; - yield return new object[] { "pl-PL", "AM" }; - yield return new object[] { "pt-BR", "AM" }; - yield return new object[] { "pt-PT", "da manhã" }; - yield return new object[] { "ro-RO", "a.m." }; - yield return new object[] { "ru-RU", "AM" }; - yield return new object[] { "sk-SK", "AM" }; - yield return new object[] { "sl-SI", "dop." }; - yield return new object[] { "sr-Cyrl-RS", "AM" }; // пре подне - yield return new object[] { "sr-Latn-RS", "AM" }; // pre podne - yield return new object[] { "sv-AX", "fm" }; - yield return new object[] { "sv-SE", "fm" }; - yield return new object[] { "sw-CD", "AM" }; - yield return new object[] { "sw-KE", "AM" }; - yield return new object[] { "sw-TZ", "AM" }; - yield return new object[] { "sw-UG", "AM" }; - string tamilAMDesignator = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "முற்பகல்" : "AM"; // முற்பகல் - yield return new object[] { "ta-IN", tamilAMDesignator }; - yield return new object[] { "ta-LK", tamilAMDesignator }; - yield return new object[] { "ta-MY", tamilAMDesignator }; - yield return new object[] { "ta-SG", tamilAMDesignator }; - yield return new object[] { "te-IN", "AM" }; - yield return new object[] { "th-TH", "ก่อนเที่ยง" }; - yield return new object[] { "tr-CY", "ÖÖ" }; - yield return new object[] { "tr-TR", "ÖÖ" }; - yield return new object[] { "uk-UA", "дп" }; - yield return new object[] { "vi-VN", "SA" }; - yield return new object[] { "zh-CN", "上午" }; - yield return new object[] { "zh-Hans-HK", "上午" }; - yield return new object[] { "zh-SG", "上午" }; - yield return new object[] { "zh-HK", "上午" }; - yield return new object[] { "zh-TW", "上午" }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(AMDesignator_Get_TestData_HybridGlobalization))] - public void AMDesignator_Get_ReturnsExpected_HybridGlobalization(string cultureName, string expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - Assert.True(expected == format.AMDesignator, $"Failed for culture: {cultureName}. Expected: {expected}, Actual: {format.AMDesignator}"); - } - [Theory] [InlineData("")] [InlineData("AA")] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs index da84d4bb51984..1d94d9b32631a 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoAbbreviatedDayNames.cs @@ -34,63 +34,6 @@ public static IEnumerable AbbreviatedDayNames_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, new string[] { "dim.", "lun.", "mar.", "mer.", "jeu.", "ven.", "sam." } }; } - public static IEnumerable AbbreviatedDayNames_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", new string[] { "الأحد", "الاثنين", "الثلاثاء", "الأربعاء", "الخميس", "الجمعة", "السبت" } }; - yield return new object[] { "am-ET", new string[] { "እሑድ", "ሰኞ", "ማክሰ", "ረቡዕ", "ሐሙስ", "ዓርብ", "ቅዳሜ" } }; - yield return new object[] { "bg-BG", new string[] { "нд", "пн", "вт", "ср", "чт", "пт", "сб" } }; - yield return new object[] { "bn-BD", new string[] { "রবি", "সোম", "মঙ্গল", "বুধ", "বৃহস্পতি", "শুক্র", "শনি" } }; - yield return new object[] { "ca-AD", new string[] { "dg.", "dl.", "dt.", "dc.", "dj.", "dv.", "ds." } }; - yield return new object[] { "cs-CZ", new string[] { "ne", "po", "út", "st", "čt", "pá", "so" } }; - yield return new object[] { "da-DK", new string[] { "søn.", "man.", "tirs.", "ons.", "tors.", "fre.", "lør." } }; - yield return new object[] { "de-DE", new string[] { "So", "Mo", "Di", "Mi", "Do", "Fr", "Sa" } }; - yield return new object[] { "el-GR", new string[] { "Κυρ", "Δευ", "Τρί", "Τετ", "Πέμ", "Παρ", "Σάβ" } }; - yield return new object[] { "en-CA", new string[] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" } }; // should be with dots - yield return new object[] { "en-US", new string[] { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" } }; - yield return new object[] { "es-419", new string[] { "dom", "lun", "mar", "mié", "jue", "vie", "sáb" } }; // should be with dots like all "es-*" - yield return new object[] { "et-EE", new string[] { "P", "E", "T", "K", "N", "R", "L" } }; - yield return new object[] { "fa-IR", new string[] { "یکشنبه", "دوشنبه", "سه‌شنبه", "چهارشنبه", "پنجشنبه", "جمعه", "شنبه" } }; - yield return new object[] { "fi-FI", new string[] { "su", "ma", "ti", "ke", "to", "pe", "la" } }; - yield return new object[] { "fil-PH", new string[] { "Lin", "Lun", "Mar", "Miy", "Huw", "Biy", "Sab" } }; - yield return new object[] { "fr-BE", new string[] { "dim.", "lun.", "mar.", "mer.", "jeu.", "ven.", "sam." } }; - yield return new object[] { "gu-IN", new string[] { "રવિ", "સોમ", "મંગળ", "બુધ", "ગુરુ", "શુક્ર", "શનિ" } }; - yield return new object[] { "he-IL", new string[] { "יום א׳", "יום ב׳", "יום ג׳", "יום ד׳", "יום ה׳", "יום ו׳", "שבת" } }; - yield return new object[] { "hr-BA", new string[] { "ned", "pon", "uto", "sri", "čet", "pet", "sub" } }; - yield return new object[] { "hu-HU", new string[] { "V", "H", "K", "Sze", "Cs", "P", "Szo" } }; - yield return new object[] { "id-ID", new string[] { "Min", "Sen", "Sel", "Rab", "Kam", "Jum", "Sab" } }; - yield return new object[] { "it-CH", new string[] { "dom", "lun", "mar", "mer", "gio", "ven", "sab" } }; - yield return new object[] { "it-IT", new string[] { "dom", "lun", "mar", "mer", "gio", "ven", "sab" } }; - yield return new object[] { "ja-JP", new string[] { "日", "月", "火", "水", "木", "金", "土" } }; - yield return new object[] { "kn-IN", new string[] { "ಭಾನು", "ಸೋಮ", "ಮಂಗಳ", "ಬುಧ", "ಗುರು", "ಶುಕ್ರ", "ಶನಿ" } }; - yield return new object[] { "ko-KR", new string[] { "일", "월", "화", "수", "목", "금", "토" } }; - yield return new object[] { "lt-LT", new string[] { "sk", "pr", "an", "tr", "kt", "pn", "št" } }; - yield return new object[] { "lv-LV", new string[] { "Svētd.", "Pirmd.", "Otrd.", "Trešd.", "Ceturtd.", "Piektd.", "Sestd." } }; - yield return new object[] { "ml-IN", new string[] { "ഞായർ", "തിങ്കൾ", "ചൊവ്വ", "ബുധൻ", "വ്യാഴം", "വെള്ളി", "ശനി" } }; - yield return new object[] { "mr-IN", new string[] { "रवि", "सोम", "मंगळ", "बुध", "गुरु", "शुक्र", "शनि" } }; - yield return new object[] { "ms-BN", new string[] { "Ahd", "Isn", "Sel", "Rab", "Kha", "Jum", "Sab" } }; - yield return new object[] { "nb-NO", new string[] { "søn.", "man.", "tir.", "ons.", "tor.", "fre.", "lør." } }; - yield return new object[] { "nl-AW", new string[] { "zo", "ma", "di", "wo", "do", "vr", "za" } }; - yield return new object[] { "pl-PL", new string[] { "niedz.", "pon.", "wt.", "śr.", "czw.", "pt.", "sob." } }; - yield return new object[] { "pt-BR", new string[] { "dom.", "seg.", "ter.", "qua.", "qui.", "sex.", "sáb." } }; - yield return new object[] { "pt-PT", new string[] { "domingo", "segunda", "terça", "quarta", "quinta", "sexta", "sábado" } }; - yield return new object[] { "ro-RO", new string[] { "dum.", "lun.", "mar.", "mie.", "joi", "vin.", "sâm." } }; - yield return new object[] { "ru-RU", new string[] { "вс", "пн", "вт", "ср", "чт", "пт", "сб" } }; - yield return new object[] { "sk-SK", new string[] { "ne", "po", "ut", "st", "št", "pi", "so" } }; - yield return new object[] { "sl-SI", new string[] { "ned.", "pon.", "tor.", "sre.", "čet.", "pet.", "sob." } }; - yield return new object[] { "sr-Cyrl-RS", new string[] { "нед", "пон", "уто", "сре", "чет", "пет", "суб" } }; - yield return new object[] { "sr-Latn-RS", new string[] { "ned", "pon", "uto", "sre", "čet", "pet", "sub" } }; - yield return new object[] { "sv-AX", new string[] { "sön", "mån", "tis", "ons", "tors", "fre", "lör" } }; - yield return new object[] { "sv-SE", new string[] { "sön", "mån", "tis", "ons", "tors", "fre", "lör" } }; - yield return new object[] { "sw-CD", new string[] { "Jumapili", "Jumatatu", "Jumanne", "Jumatano", "Alhamisi", "Ijumaa", "Jumamosi" } }; - yield return new object[] { "ta-IN", new string[] { "ஞாயி.", "திங்.", "செவ்.", "புத.", "வியா.", "வெள்.", "சனி" } }; - yield return new object[] { "te-IN", new string[] { "ఆది", "సోమ", "మంగళ", "బుధ", "గురు", "శుక్ర", "శని" } }; - yield return new object[] { "th-TH", new string[] { "อา.", "จ.", "อ.", "พ.", "พฤ.", "ศ.", "ส." } }; - yield return new object[] { "tr-CY", new string[] { "Paz", "Pzt", "Sal", "Çar", "Per", "Cum", "Cmt" } }; - yield return new object[] { "uk-UA", new string[] { "нд", "пн", "вт", "ср", "чт", "пт", "сб" } }; - yield return new object[] { "vi-VN", new string[] { "CN", "Th 2", "Th 3", "Th 4", "Th 5", "Th 6", "Th 7" } }; - yield return new object[] { "zh-CN", new string[] { "周日", "周一", "周二", "周三", "周四", "周五", "周六" } }; - } [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(AbbreviatedDayNames_Get_TestData_ICU))] @@ -99,16 +42,6 @@ public void AbbreviatedDayNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo forma Assert.Equal(expected, format.AbbreviatedDayNames); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(AbbreviatedDayNames_Get_TestData_HybridGlobalization))] - public void AbbreviatedDayNames_Get_ReturnsExpected_HybridGlobalization(string cultureName, string[] expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - int length = format.AbbreviatedDayNames.Length; - Assert.True(length == expected.Length, $"Length comparison failed for culture: {cultureName}. Expected: {expected.Length}, Actual: {length}"); - for (int i = 0; i AbbreviatedMonthGenitiveNames_Get_TestData_I yield return new object[] { CultureInfo.GetCultureInfo("en-US").DateTimeFormat, new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; } - public static IEnumerable AbbreviatedMonthGenitiveNames_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", new string[] { "محرم", "صفر", "ربيع الأول", "ربيع الآخر", "جمادى الأولى", "جمادى الآخرة", "رجب", "شعبان", "رمضان", "شوال", "ذو القعدة", "ذو الحجة", "" } }; - if (PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS) - { - yield return new object[] { "am-ET", new string[] { "ጃንዩ", "ፌብሩ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" } }; - yield return new object[] { "es-MX", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - } - else - { - yield return new object[] { "am-ET", new string[] { "ጃን", "ፌብ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" } }; // "ጃንዩ", "ፌብሩ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" - yield return new object[] { "es-MX", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sep", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - } - yield return new object[] { "bg-BG", new string[] { "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", "" } }; //"яну", "фев", "март", "апр", "май", "юни", "юли", "авг", "сеп", "окт", "ное", "дек", "" - yield return new object[] { "bn-BD", new string[] { "জানু", "ফেব", "মার্চ", "এপ্রি", "মে", "জুন", "জুল", "আগ", "সেপ", "অক্টো", "নভে", "ডিসে", "" } }; // "জানু", "ফেব", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" - yield return new object[] { "bn-IN", new string[] { "জানু", "ফেব", "মার্চ", "এপ্রি", "মে", "জুন", "জুল", "আগ", "সেপ্টেঃ", "অক্টোঃ", "নভেঃ", "ডিসেঃ", "" } }; // "জানু", "ফেব", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" - yield return new object[] { "ca-AD", new string[] { "gen.", "febr.", "març", "abr.", "maig", "juny", "jul.", "ag.", "set.", "oct.", "nov.", "des.", "" } }; // "de gen.", "de febr.", "de març", "d’abr.", "de maig", "de juny", "de jul.", "d’ag.", "de set.", "d’oct.", "de nov.", "de des.", "" - yield return new object[] { "ca-ES", new string[] { "gen.", "febr.", "març", "abr.", "maig", "juny", "jul.", "ag.", "set.", "oct.", "nov.", "des.", "" } }; - yield return new object[] { "cs-CZ", new string[] { "led", "úno", "bře", "dub", "kvě", "čvn", "čvc", "srp", "zář", "říj", "lis", "pro", "" } }; - yield return new object[] { "da-DK", new string[] { "jan.", "feb.", "mar.", "apr.", "maj", "jun.", "jul.", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "de-AT", new string[] { "Jän.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sep.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-BE", new string[] { "Jan.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-CH", new string[] { "Jan.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-DE", new string[] { "Jan.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-IT", new string[] { "Jän.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sep.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-LI", new string[] { "Jan.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "de-LU", new string[] { "Jan.", "Feb.", "März", "Apr.", "Mai", "Juni", "Juli", "Aug.", "Sept.", "Okt.", "Nov.", "Dez.", "" } }; - yield return new object[] { "el-CY", new string[] { "Ιαν", "Φεβ", "Μαρ", "Απρ", "Μαΐ", "Ιουν", "Ιουλ", "Αυγ", "Σεπ", "Οκτ", "Νοε", "Δεκ", "" } }; - yield return new object[] { "el-GR", new string[] { "Ιαν", "Φεβ", "Μαρ", "Απρ", "Μαΐ", "Ιουν", "Ιουλ", "Αυγ", "Σεπ", "Οκτ", "Νοε", "Δεκ", "" } }; - yield return new object[] { "en-AE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-AG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-AI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-AS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-AT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-AU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "June", "July", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Jun", "Jul", .., "Sep" - yield return new object[] { "en-BB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-BM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; // "Jan.", "Feb.", "Mar.", "Apr.", "May", "Jun.", "Jul.", "Aug.", "Sep.", "Oct.", "Nov.", "Dec.", "" - yield return new object[] { "en-CC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CX", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ER", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FJ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GD", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-GY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-HK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-JE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-JM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-MO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MP", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-MS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NF", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-PK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-PW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-RW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SD", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SX", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TV", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-UG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-UM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-US", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-VC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-VG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-VI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-VU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-WS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "es-419", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "es-ES", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "et-EE", new string[] { "jaan", "veebr", "märts", "apr", "mai", "juuni", "juuli", "aug", "sept", "okt", "nov", "dets", "" } }; - yield return new object[] { "fa-IR", new string[] { "فروردین", "اردیبهشت", "خرداد", "تیر", "مرداد", "شهریور", "مهر", "آبان", "آذر", "دی", "بهمن", "اسفند", "" } }; - yield return new object[] { "fi-FI", new string[] { "tammik.", "helmik.", "maalisk.", "huhtik.", "toukok.", "kesäk.", "heinäk.", "elok.", "syysk.", "lokak.", "marrask.", "jouluk.", "" } }; - yield return new object[] { "fil-PH", new string[] { "Ene", "Peb", "Mar", "Abr", "May", "Hun", "Hul", "Ago", "Set", "Okt", "Nob", "Dis", "" } }; - yield return new object[] { "fr-BE", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-CA", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juill.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-CH", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-FR", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "gu-IN", new string[] { "જાન્યુ", "ફેબ્રુ", "માર્ચ", "એપ્રિલ", "મે", "જૂન", "જુલાઈ", "ઑગસ્ટ", "સપ્ટે", "ઑક્ટો", "નવે", "ડિસે", "" } }; - yield return new object[] { "he-IL", new string[] { "ינו׳", "פבר׳", "מרץ", "אפר׳", "מאי", "יוני", "יולי", "אוג׳", "ספט׳", "אוק׳", "נוב׳", "דצמ׳", "" } }; - yield return new object[] { "hi-IN", new string[] { "जन॰", "फ़र॰", "मार्च", "अप्रैल", "मई", "जून", "जुल॰", "अग॰", "सित॰", "अक्तू॰", "नव॰", "दिस॰", "" } }; - yield return new object[] { "hr-BA", new string[] { "sij", "velj", "ožu", "tra", "svi", "lip", "srp", "kol", "ruj", "lis", "stu", "pro", "" } }; - yield return new object[] { "hr-HR", new string[] { "sij", "velj", "ožu", "tra", "svi", "lip", "srp", "kol", "ruj", "lis", "stu", "pro", "" } }; - yield return new object[] { "hu-HU", new string[] { "jan.", "febr.", "márc.", "ápr.", "máj.", "jún.", "júl.", "aug.", "szept.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "id-ID", new string[] { "Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Agu", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "it-CH", new string[] { "gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic", "" } }; - yield return new object[] { "it-IT", new string[] { "gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic", "" } }; - yield return new object[] { "ja-JP", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "kn-IN", new string[] { "ಜನವರಿ", "ಫೆಬ್ರವರಿ", "ಮಾರ್ಚ್", "ಏಪ್ರಿ", "ಮೇ", "ಜೂನ್", "ಜುಲೈ", "ಆಗಸ್ಟ್", "ಸೆಪ್ಟೆಂ", "ಅಕ್ಟೋ", "ನವೆಂ", "ಡಿಸೆಂ", "" } }; // "ಜನವರಿ", "ಫೆಬ್ರವರಿ", "ಮಾರ್ಚ್", "ಏಪ್ರಿ", "ಮೇ", "ಜೂನ್", "ಜುಲೈ", "ಆಗ", "ಸೆಪ್ಟೆಂ", "ಅಕ್ಟೋ", "ನವೆಂ", "ಡಿಸೆಂ", "" - yield return new object[] { "ko-KR", new string[] { "1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월", "" } }; - yield return new object[] { "lt-LT", new string[] { "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", "" } }; // "saus.", "vas.", "kov.", "bal.", "geg.", "birž.", "liep.", "rugp.", "rugs.", "spal.", "lapkr.", "gruod." - yield return new object[] { "lv-LV", new string[] { "janv.", "febr.", "marts", "apr.", "maijs", "jūn.", "jūl.", "aug.", "sept.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "ml-IN", new string[] { "ജനു", "ഫെബ്രു", "മാർ", "ഏപ്രി", "മേയ്", "ജൂൺ", "ജൂലൈ", "ഓഗ", "സെപ്റ്റം", "ഒക്ടോ", "നവം", "ഡിസം", "" } }; - yield return new object[] { "mr-IN", new string[] { "जाने", "फेब्रु", "मार्च", "एप्रि", "मे", "जून", "जुलै", "ऑग", "सप्टें", "ऑक्टो", "नोव्हें", "डिसें", "" } }; - yield return new object[] { "ms-BN", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - yield return new object[] { "ms-MY", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - yield return new object[] { "ms-SG", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - string[] norwegianMonths = new string [] { "jan.", "feb.", "mars", "apr.", "mai", "juni", "juli", "aug.", "sep.", "okt.", "nov.", "des.", "" }; // "jan.", "feb.", "mar.", "apr.", "mai", "jun.", "jul.", "aug.", "sep.", "okt.", "nov.", "des.", " - yield return new object[] { "nb-NO", norwegianMonths }; - yield return new object[] { "no-NO", norwegianMonths }; - string[] dutchMonths = new string[] { "jan", "feb", "mrt", "apr", "mei", "jun", "jul", "aug", "sep", "okt", "nov", "dec", "" }; // "jan.", "feb.", "mrt.", "apr.", "mei", "jun.", "jul.", "aug.", "sep.", "okt.", "nov.", "dec.", "" - yield return new object[] { "nl-AW", dutchMonths }; - yield return new object[] { "nl-BE", dutchMonths }; - yield return new object[] { "nl-NL", dutchMonths }; - yield return new object[] { "pl-PL", new string[] { "sty", "lut", "mar", "kwi", "maj", "cze", "lip", "sie", "wrz", "paź", "lis", "gru", "" } }; - yield return new object[] { "pt-BR", new string[] { "jan.", "fev.", "mar.", "abr.", "mai.", "jun.", "jul.", "ago.", "set.", "out.", "nov.", "dez.", "" } }; - yield return new object[] { "pt-PT", new string[] { "jan.", "fev.", "mar.", "abr.", "mai.", "jun.", "jul.", "ago.", "set.", "out.", "nov.", "dez.", "" } }; - yield return new object[] { "ro-RO", new string[] { "ian.", "feb.", "mar.", "apr.", "mai", "iun.", "iul.", "aug.", "sept.", "oct.", "nov.", "dec.", "" } }; - yield return new object[] { "ru-RU", new string[] { "янв.", "февр.", "мар.", "апр.", "мая", "июн.", "июл.", "авг.", "сент.", "окт.", "нояб.", "дек.", "" } }; - yield return new object[] { "sk-SK", new string[] { "jan", "feb", "mar", "apr", "máj", "jún", "júl", "aug", "sep", "okt", "nov", "dec", "" } }; - yield return new object[] { "sl-SI", new string[] { "jan.", "feb.", "mar.", "apr.", "maj", "jun.", "jul.", "avg.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sr-Cyrl-RS", new string[] { "јан", "феб", "мар", "апр", "мај", "јун", "јул", "авг", "сеп", "окт", "нов", "дец", "" } }; - yield return new object[] { "sr-Latn-RS", new string[] { "jan", "feb", "mar", "apr", "maj", "jun", "jul", "avg", "sep", "okt", "nov", "dec", "" } }; - yield return new object[] { "sv-AX", new string[] { "jan.", "feb.", "mars", "apr.", "maj", "juni", "juli", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sv-SE", new string[] { "jan.", "feb.", "mars", "apr.", "maj", "juni", "juli", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sw-CD", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-KE", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-TZ", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-UG", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "ta-IN", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-LK", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-MY", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-SG", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "te-IN", new string[] { "జన", "ఫిబ్ర", "మార్చి", "ఏప్రి", "మే", "జూన్", "జులై", "ఆగ", "సెప్టెం", "అక్టో", "నవం", "డిసెం", "" } }; - yield return new object[] { "th-TH", new string[] { "ม.ค.", "ก.พ.", "มี.ค.", "เม.ย.", "พ.ค.", "มิ.ย.", "ก.ค.", "ส.ค.", "ก.ย.", "ต.ค.", "พ.ย.", "ธ.ค.", "" } }; - yield return new object[] { "tr-CY", new string[] { "Oca", "Şub", "Mar", "Nis", "May", "Haz", "Tem", "Ağu", "Eyl", "Eki", "Kas", "Ara", "" } }; - yield return new object[] { "tr-TR", new string[] { "Oca", "Şub", "Mar", "Nis", "May", "Haz", "Tem", "Ağu", "Eyl", "Eki", "Kas", "Ara", "" } }; - yield return new object[] { "uk-UA", new string[] { "січ.", "лют.", "бер.", "квіт.", "трав.", "черв.", "лип.", "серп.", "вер.", "жовт.", "лист.", "груд.", "" } }; - string vietnameseAbbrMonth = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "Thg" : "Tháng"; // thg - yield return new object[] { "vi-VN", new string[] { $"{vietnameseAbbrMonth} 1", $"{vietnameseAbbrMonth} 2", $"{vietnameseAbbrMonth} 3", $"{vietnameseAbbrMonth} 4", $"{vietnameseAbbrMonth} 5", $"{vietnameseAbbrMonth} 6", $"{vietnameseAbbrMonth} 7", $"{vietnameseAbbrMonth} 8", $"{vietnameseAbbrMonth} 9", $"{vietnameseAbbrMonth} 10", $"{vietnameseAbbrMonth} 11", $"{vietnameseAbbrMonth} 12", "" } }; - yield return new object[] { "zh-CN", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-Hans-HK", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-SG", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-HK", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-TW", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - } [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(AbbreviatedMonthGenitiveNames_Get_TestData_ICU))] @@ -221,17 +21,6 @@ public void AbbreviatedMonthGenitiveNames_Get_ReturnsExpected_ICU(DateTimeFormat Assert.Equal(expected, format.AbbreviatedMonthGenitiveNames); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(AbbreviatedMonthGenitiveNames_Get_TestData_HybridGlobalization))] - public void AbbreviatedMonthGenitiveNames_Get_ReturnsExpected_HybridGlobalization(string cultureName, string[] expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - int length = format.AbbreviatedMonthGenitiveNames.Length; - Assert.True(length == expected.Length, $"Length comparison failed for culture: {cultureName}. Expected: {expected.Length}, Actual: {length}"); - for (int i = 0; i AbbreviatedMonthNames_Get_TestData_ICU() } - public static IEnumerable AbbreviatedMonthNames_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", new string[] { "محرم", "صفر", "ربيع الأول", "ربيع الآخر", "جمادى الأولى", "جمادى الآخرة", "رجب", "شعبان", "رمضان", "شوال", "ذو القعدة", "ذو الحجة", "" } }; - if (PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS) - { - yield return new object[] { "am-ET", new string[] { "ጃንዩ", "ፌብሩ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" } }; - yield return new object[] { "en-AU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "es-MX", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "uk-UA", new string[] { "січ", "лют", "бер", "кві", "тра", "чер", "лип", "сер", "вер", "жов", "лис", "гру", "" } }; - yield return new object[] { "vi-VN", new string[] { "Thg 1", "Thg 2", "Thg 3", "Thg 4", "Thg 5", "Thg 6", "Thg 7", "Thg 8", "Thg 9", "Thg 10", "Thg 11", "Thg 12", "" } }; - } - else - { - yield return new object[] { "am-ET", new string[] { "ጃን", "ፌብ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" } }; // "ጃንዩ", "ፌብሩ", "ማርች", "ኤፕሪ", "ሜይ", "ጁን", "ጁላይ", "ኦገስ", "ሴፕቴ", "ኦክቶ", "ኖቬም", "ዲሴም", "" - yield return new object[] { "en-AU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "June", "July", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Jun", "Jul" - yield return new object[] { "es-MX", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sep", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "uk-UA", new string[] { "січ.", "лют.", "бер.", "квіт.", "трав.", "черв.", "лип.", "серп.", "вер.", "жовт.", "лист.", "груд.", "" } }; // "січ", "лют", "бер", "кві", "тра", "чер", "лип", "сер", "вер", "жов", "лис", "гру", "" - yield return new object[] { "vi-VN", new string[] { "Tháng 1", "Tháng 2", "Tháng 3", "Tháng 4", "Tháng 5", "Tháng 6", "Tháng 7", "Tháng 8", "Tháng 9", "Tháng 10", "Tháng 11", "Tháng 12", "" } }; - } - yield return new object[] { "bg-BG", new string[] { "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", "" } }; // "яну", "фев", "март", "апр", "май", "юни", "юли", "авг", "сеп", "окт", "ное", "дек", "" - yield return new object[] { "bn-BD", new string[] { "জানু", "ফেব", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" } }; // "জানুয়ারী", "ফেব্রুয়ারী", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" - yield return new object[] { "bn-IN", new string[] { "জানু", "ফেব", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেঃ", "অক্টোঃ", "নভেঃ", "ডিসেঃ", "" } }; // BUG. JS returns Genitive even though we expect Nominative; "জানু", "ফেব", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" - yield return new object[] { "ca-AD", new string[] { "gen.", "febr.", "març", "abr.", "maig", "juny", "jul.", "ag.", "set.", "oct.", "nov.", "des.", "" } }; - yield return new object[] { "ca-ES", new string[] { "gen.", "febr.", "març", "abr.", "maig", "juny", "jul.", "ag.", "set.", "oct.", "nov.", "des.", "" } }; - yield return new object[] { "cs-CZ", new string[] { "led", "úno", "bře", "dub", "kvě", "čvn", "čvc", "srp", "zář", "říj", "lis", "pro", "" } }; - yield return new object[] { "da-DK", new string[] { "jan.", "feb.", "mar.", "apr.", "maj", "jun.", "jul.", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "de-AT", new string[] { "Jän", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-BE", new string[] { "Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-CH", new string[] { "Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-DE", new string[] { "Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-IT", new string[] { "Jän", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-LI", new string[] { "Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "de-LU", new string[] { "Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez", "" } }; - yield return new object[] { "el-CY", new string[] { "Ιαν", "Φεβ", "Μαρ", "Απρ", "Μαΐ", "Ιουν", "Ιουλ", "Αυγ", "Σεπ", "Οκτ", "Νοε", "Δεκ", "" } }; // BUG. JS returns Genitive for Greek even though we expect Nominative; "Ιαν", "Φεβ", "Μάρ", "Απρ", "Μάι", "Ιούν", "Ιούλ", "Αύγ", "Σεπ", "Οκτ", "Νοέ", "Δεκ", "" - yield return new object[] { "el-GR", new string[] { "Ιαν", "Φεβ", "Μαρ", "Απρ", "Μαΐ", "Ιουν", "Ιουλ", "Αυγ", "Σεπ", "Οκτ", "Νοε", "Δεκ", "" } }; // BUG. - yield return new object[] { "en-AE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-AG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-AI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-AS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-AT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-BM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-BZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; // "Jan.", "Feb.", "Mar.", "Apr.", "May", "Jun.", "Jul.", "Aug.", "Sep.", "Oct.", "Nov.", "Dec.", "" - yield return new object[] { "en-CC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CX", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-CY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-DM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ER", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FJ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-FM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GD", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-GU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-GY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-HK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-IO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-JE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-JM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-KY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-LS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-MO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MP", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-MS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-MY", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NF", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-NZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-PK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PN", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-PR", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-PW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-RW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SB", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SD", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SE", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SH", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SL", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SX", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-SZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TK", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TO", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TT", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TV", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-TZ", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-UG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-UM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-US", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-VC", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-VG", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-VI", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec", "" } }; - yield return new object[] { "en-VU", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-WS", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZA", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZM", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "en-ZW", new string[] { "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sept", "Oct", "Nov", "Dec", "" } }; // "Sep" - yield return new object[] { "es-419", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "es-ES", new string[] { "ene", "feb", "mar", "abr", "may", "jun", "jul", "ago", "sept", "oct", "nov", "dic", "" } }; // "ene.", "feb.", "mar.", "abr.", "may.", "jun.", "jul.", "ago.", "sep.", "oct.", "nov.", "dic.", "" - yield return new object[] { "et-EE", new string[] { "jaanuar", "veebruar", "märts", "aprill", "mai", "juuni", "juuli", "august", "september", "oktoober", "november", "detsember", "" } }; // "jaan", "veebr", "märts", "apr", "mai", "juuni", "juuli", "aug", "sept", "okt", "nov", "dets", "" - yield return new object[] { "fa-IR", new string[] { "فروردین", "اردیبهشت", "خرداد", "تیر", "مرداد", "شهریور", "مهر", "آبان", "آذر", "دی", "بهمن", "اسفند", "" } }; - yield return new object[] { "fi-FI", new string[] { "tammi", "helmi", "maalis", "huhti", "touko", "kesä", "heinä", "elo", "syys", "loka", "marras", "joulu", "" } }; - yield return new object[] { "fil-PH", new string[] { "Ene", "Peb", "Mar", "Abr", "May", "Hun", "Hul", "Ago", "Set", "Okt", "Nob", "Dis", "" } }; - yield return new object[] { "fr-BE", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-CA", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juill.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-CH", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "fr-FR", new string[] { "janv.", "févr.", "mars", "avr.", "mai", "juin", "juil.", "août", "sept.", "oct.", "nov.", "déc.", "" } }; - yield return new object[] { "gu-IN", new string[] { "જાન્યુ", "ફેબ્રુ", "માર્ચ", "એપ્રિલ", "મે", "જૂન", "જુલાઈ", "ઑગસ્ટ", "સપ્ટે", "ઑક્ટો", "નવે", "ડિસે", "" } }; - yield return new object[] { "he-IL", new string[] { "ינו׳", "פבר׳", "מרץ", "אפר׳", "מאי", "יוני", "יולי", "אוג׳", "ספט׳", "אוק׳", "נוב׳", "דצמ׳", "" } }; - yield return new object[] { "hi-IN", new string[] { "जन॰", "फ़र॰", "मार्च", "अप्रैल", "मई", "जून", "जुल॰", "अग॰", "सित॰", "अक्तू॰", "नव॰", "दिस॰", "" } }; - yield return new object[] { "hr-BA", new string[] { "sij", "velj", "ožu", "tra", "svi", "lip", "srp", "kol", "ruj", "lis", "stu", "pro", "" } }; - yield return new object[] { "hr-HR", new string[] { "sij", "velj", "ožu", "tra", "svi", "lip", "srp", "kol", "ruj", "lis", "stu", "pro", "" } }; - yield return new object[] { "hu-HU", new string[] { "jan.", "febr.", "márc.", "ápr.", "máj.", "jún.", "júl.", "aug.", "szept.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "id-ID", new string[] { "Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Agu", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "it-CH", new string[] { "gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic", "" } }; - yield return new object[] { "it-IT", new string[] { "gen", "feb", "mar", "apr", "mag", "giu", "lug", "ago", "set", "ott", "nov", "dic", "" } }; - yield return new object[] { "ja-JP", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "kn-IN", new string[] { "ಜನ", "ಫೆಬ್ರ", "ಮಾರ್ಚ್", "ಏಪ್ರಿ", "ಮೇ", "ಜೂನ್", "ಜುಲೈ", "ಆಗ", "ಸೆಪ್ಟೆಂ", "ಅಕ್ಟೋ", "ನವೆಂ", "ಡಿಸೆಂ", "" } }; - yield return new object[] { "ko-KR", new string[] { "1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월", "" } }; - yield return new object[] { "lt-LT", new string[] { "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", "" } }; // "saus.", "vas.", "kov.", "bal.", "geg.", "birž.", "liep.", "rugp.", "rugs.", "spal.", "lapkr.", "gruod." - yield return new object[] { "lv-LV", new string[] { "janv.", "febr.", "marts", "apr.", "maijs", "jūn.", "jūl.", "aug.", "sept.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "ml-IN", new string[] { "ജനു", "ഫെബ്രു", "മാർ", "ഏപ്രി", "മേയ്", "ജൂൺ", "ജൂലൈ", "ഓഗ", "സെപ്റ്റം", "ഒക്ടോ", "നവം", "ഡിസം", "" } }; - yield return new object[] { "mr-IN", new string[] { "जाने", "फेब्रु", "मार्च", "एप्रि", "मे", "जून", "जुलै", "ऑग", "सप्टें", "ऑक्टो", "नोव्हें", "डिसें", "" } }; - yield return new object[] { "ms-BN", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - yield return new object[] { "ms-MY", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - yield return new object[] { "ms-SG", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis", "" } }; - yield return new object[] { "nb-NO", new string[] { "jan", "feb", "mar", "apr", "mai", "jun", "jul", "aug", "sep", "okt", "nov", "des", "" } }; - yield return new object[] { "no", new string[] { "jan", "feb", "mar", "apr", "mai", "jun", "jul", "aug", "sep", "okt", "nov", "des", "" } }; - yield return new object[] { "no-NO", new string[] { "jan", "feb", "mar", "apr", "mai", "jun", "jul", "aug", "sep", "okt", "nov", "des", "" } }; - var dutchMonths = new string[] { "jan", "feb", "mrt", "apr", "mei", "jun", "jul", "aug", "sep", "okt", "nov", "dec", "" }; // "jan.", "feb.", "mrt.", "apr.", "mei", "jun.", "jul.", "aug.", "sep.", "okt.", "nov.", "dec.", "" - yield return new object[] { "nl-AW", dutchMonths }; - yield return new object[] { "nl-BE", dutchMonths }; - yield return new object[] { "nl-NL", dutchMonths }; - yield return new object[] { "pl-PL", new string[] { "sty", "lut", "mar", "kwi", "maj", "cze", "lip", "sie", "wrz", "paź", "lis", "gru", "" } }; - yield return new object[] { "pt-BR", new string[] { "jan.", "fev.", "mar.", "abr.", "mai.", "jun.", "jul.", "ago.", "set.", "out.", "nov.", "dez.", "" } }; - yield return new object[] { "pt-PT", new string[] { "jan.", "fev.", "mar.", "abr.", "mai.", "jun.", "jul.", "ago.", "set.", "out.", "nov.", "dez.", "" } }; - yield return new object[] { "ro-RO", new string[] { "ian.", "feb.", "mar.", "apr.", "mai", "iun.", "iul.", "aug.", "sept.", "oct.", "nov.", "dec.", "" } }; - yield return new object[] { "ru-RU", new string[] { "янв.", "февр.", "март", "апр.", "май", "июнь", "июль", "авг.", "сент.", "окт.", "нояб.", "дек.", "" } }; - yield return new object[] { "sk-SK", new string[] { "jan", "feb", "mar", "apr", "máj", "jún", "júl", "aug", "sep", "okt", "nov", "dec", "" } }; - yield return new object[] { "sl-SI", new string[] { "jan.", "feb.", "mar.", "apr.", "maj", "jun.", "jul.", "avg.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sr-Cyrl-RS", new string[] { "јан", "феб", "мар", "апр", "мај", "јун", "јул", "авг", "сеп", "окт", "нов", "дец", "" } }; - yield return new object[] { "sr-Latn-RS", new string[] { "jan", "feb", "mar", "apr", "maj", "jun", "jul", "avg", "sep", "okt", "nov", "dec", "" } }; - yield return new object[] { "sv-AX", new string[] { "jan.", "feb.", "mars", "apr.", "maj", "juni", "juli", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sv-SE", new string[] { "jan.", "feb.", "mars", "apr.", "maj", "juni", "juli", "aug.", "sep.", "okt.", "nov.", "dec.", "" } }; - yield return new object[] { "sw-CD", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-KE", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-TZ", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "sw-UG", new string[] { "Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des", "" } }; - yield return new object[] { "ta-IN", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-LK", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-MY", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "ta-SG", new string[] { "ஜன.", "பிப்.", "மார்.", "ஏப்.", "மே", "ஜூன்", "ஜூலை", "ஆக.", "செப்.", "அக்.", "நவ.", "டிச.", "" } }; - yield return new object[] { "te-IN", new string[] { "జన", "ఫిబ్ర", "మార్చి", "ఏప్రి", "మే", "జూన్", "జులై", "ఆగ", "సెప్టెం", "అక్టో", "నవం", "డిసెం", "" } }; - yield return new object[] { "th-TH", new string[] { "ม.ค.", "ก.พ.", "มี.ค.", "เม.ย.", "พ.ค.", "มิ.ย.", "ก.ค.", "ส.ค.", "ก.ย.", "ต.ค.", "พ.ย.", "ธ.ค.", "" } }; - yield return new object[] { "tr-CY", new string[] { "Oca", "Şub", "Mar", "Nis", "May", "Haz", "Tem", "Ağu", "Eyl", "Eki", "Kas", "Ara", "" } }; - yield return new object[] { "tr-TR", new string[] { "Oca", "Şub", "Mar", "Nis", "May", "Haz", "Tem", "Ağu", "Eyl", "Eki", "Kas", "Ara", "" } }; - - yield return new object[] { "zh-CN", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-Hans-HK", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-SG", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-HK", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { "zh-TW", new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(AbbreviatedMonthNames_Get_TestData_ICU))] public void AbbreviatedMonthNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string[] expected) @@ -246,17 +42,6 @@ public void AbbreviatedMonthNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo for Assert.Equal(expected, format.AbbreviatedMonthNames); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(AbbreviatedMonthNames_Get_TestData_HybridGlobalization))] - public void AbbreviatedMonthNames_Get_ReturnsExpected_HybridGlobalization(string cultureName, string[] expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - int length = format.AbbreviatedMonthNames.Length; - Assert.True(length == expected.Length, $"Length comparison failed for culture: {cultureName}. Expected: {expected.Length}, Actual: {length}"); - for (int i = 0; i CalendarWeekRule_Get_TestData() // "br-FR" is not presented in Browser's ICU. Let's test ru-RU instead. yield return new object[] { "ru-RU", CalendarWeekRule.FirstFourDayWeek }; } - - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - yield return new object[] { "ar-SA", CalendarWeekRule.FirstDay }; - yield return new object[] { "am-ET", CalendarWeekRule.FirstDay }; - yield return new object[] { "bg-BG", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "bn-BD", CalendarWeekRule.FirstDay }; - yield return new object[] { "bn-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "ca-AD", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "ca-ES", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "cs-CZ", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "da-DK", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-AT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-BE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-CH", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-DE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-IT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-LI", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "de-LU", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "el-CY", CalendarWeekRule.FirstDay }; - yield return new object[] { "el-GR", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-AE", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-AG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-AI", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-AS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-AT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-AU", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BB", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-BI", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BW", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-BZ", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CA", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CC", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CH", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-CK", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CX", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-CY", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-DE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-DK", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-DM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-ER", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-FI", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-FJ", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-FK", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-FM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-GB", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-GD", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-GG", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-GH", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-GI", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-GM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-GU", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-GY", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-HK", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-IE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-IL", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-IM", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-IO", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-JE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-JM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-KE", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-KI", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-KN", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-KY", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-LC", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-LR", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-LS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MH", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MO", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MP", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MT", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MU", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MW", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-MY", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NA", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NF", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NL", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-NR", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NU", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-NZ", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PH", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PK", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PN", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PR", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-PW", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-RW", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SB", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SC", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SD", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "en-SG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SH", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SI", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SL", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SX", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-SZ", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TC", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TK", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TO", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TT", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TV", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-TZ", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-UG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-UM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-US", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-VC", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-VG", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-VI", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-VU", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-WS", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-ZA", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-ZM", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-ZW", CalendarWeekRule.FirstDay }; - yield return new object[] { "en-US", CalendarWeekRule.FirstDay }; - yield return new object[] { "es-419", CalendarWeekRule.FirstDay }; - yield return new object[] { "es-ES", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "es-MX", CalendarWeekRule.FirstDay }; - yield return new object[] { "et-EE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "fa-IR", CalendarWeekRule.FirstDay }; - yield return new object[] { "fi-FI", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "fil-PH", CalendarWeekRule.FirstDay }; - yield return new object[] { "fr-BE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "fr-CA", CalendarWeekRule.FirstDay }; - yield return new object[] { "fr-CH", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "fr-FR", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "gu-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "he-IL", CalendarWeekRule.FirstDay }; - yield return new object[] { "hi-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "hr-BA", CalendarWeekRule.FirstDay }; - yield return new object[] { "hr-HR", CalendarWeekRule.FirstDay }; - yield return new object[] { "hu-HU", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "id-ID", CalendarWeekRule.FirstDay }; - yield return new object[] { "it-CH", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "it-IT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "ja-JP", CalendarWeekRule.FirstDay }; - yield return new object[] { "kn-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "ko-KR", CalendarWeekRule.FirstDay }; - yield return new object[] { "lt-LT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "lv-LV", CalendarWeekRule.FirstDay }; - yield return new object[] { "ml-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "mr-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "ms-BN", CalendarWeekRule.FirstDay }; - yield return new object[] { "ms-MY", CalendarWeekRule.FirstDay }; - yield return new object[] { "ms-SG", CalendarWeekRule.FirstDay }; - yield return new object[] { "nb-NO", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "no-NO", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "nl-AW", CalendarWeekRule.FirstDay }; - yield return new object[] { "nl-BE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "nl-NL", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "pl-PL", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "pt-BR", CalendarWeekRule.FirstDay }; - yield return new object[] { "pt-PT", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "ro-RO", CalendarWeekRule.FirstDay }; - yield return new object[] { "ru-RU", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "sk-SK", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "sl-SI", CalendarWeekRule.FirstDay }; - yield return new object[] { "sr-Cyrl-RS", CalendarWeekRule.FirstDay }; - yield return new object[] { "sr-Latn-RS", CalendarWeekRule.FirstDay }; - yield return new object[] { "sv-AX", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "sv-SE", CalendarWeekRule.FirstFourDayWeek }; - yield return new object[] { "sw-CD", CalendarWeekRule.FirstDay }; - yield return new object[] { "sw-KE", CalendarWeekRule.FirstDay }; - yield return new object[] { "sw-TZ", CalendarWeekRule.FirstDay }; - yield return new object[] { "sw-UG", CalendarWeekRule.FirstDay }; - yield return new object[] { "ta-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "ta-LK", CalendarWeekRule.FirstDay }; - yield return new object[] { "ta-MY", CalendarWeekRule.FirstDay }; - yield return new object[] { "ta-SG", CalendarWeekRule.FirstDay }; - yield return new object[] { "te-IN", CalendarWeekRule.FirstDay }; - yield return new object[] { "th-TH", CalendarWeekRule.FirstDay }; - yield return new object[] { "tr-CY", CalendarWeekRule.FirstDay }; - yield return new object[] { "tr-TR", CalendarWeekRule.FirstDay }; - yield return new object[] { "uk-UA", CalendarWeekRule.FirstDay }; - yield return new object[] { "vi-VN", CalendarWeekRule.FirstDay }; - yield return new object[] { "zh-CN", CalendarWeekRule.FirstDay }; - yield return new object[] { "zh-Hans-HK", CalendarWeekRule.FirstDay }; - yield return new object[] { "zh-SG", CalendarWeekRule.FirstDay }; - yield return new object[] { "zh-HK", CalendarWeekRule.FirstDay }; - yield return new object[] { "zh-TW", CalendarWeekRule.FirstDay }; - } } [Theory] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoData.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoData.cs index 253d610184750..40de319b78c5d 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoData.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoData.cs @@ -69,7 +69,7 @@ public static Exception GetCultureNotSupportedException(CultureInfo cultureInfo) }; public static bool HasBadIcuTimePatterns(CultureInfo culture) { - return PlatformDetection.IsIcuGlobalizationAndNotHybridOnBrowser + return PlatformDetection.IsIcuGlobalization && _badIcuTimePatterns.TryGetValue(culture.Name, out var version) && PlatformDetection.ICUVersion < version; } diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoDayNames.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoDayNames.cs index e84949d20d8c1..203e4d003acf7 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoDayNames.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoDayNames.cs @@ -34,56 +34,6 @@ public static IEnumerable DayNames_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, new string[] { "dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi" } }; } - public static IEnumerable DayNames_Get_TestData_HybridGlobalization() - { - yield return new object[] { "ar-SA", new string[] { "الأحد", "الاثنين", "الثلاثاء", "الأربعاء", "الخميس", "الجمعة", "السبت" } }; - yield return new object[] { "am-ET", new string[] { "እሑድ", "ሰኞ", "ማክሰኞ", "ረቡዕ", "ሐሙስ", "ዓርብ", "ቅዳሜ" } }; - yield return new object[] { "bg-BG", new string[] { "неделя", "понеделник", "вторник", "сряда", "четвъртък", "петък", "събота" } }; - yield return new object[] { "bn-BD", new string[] { "রবিবার", "সোমবার", "মঙ্গলবার", "বুধবার", "বৃহস্পতিবার", "শুক্রবার", "শনিবার" } }; - yield return new object[] { "ca-ES", new string[] { "diumenge", "dilluns", "dimarts", "dimecres", "dijous", "divendres", "dissabte" } }; - yield return new object[] { "cs-CZ", new string[] { "neděle", "pondělí", "úterý", "středa", "čtvrtek", "pátek", "sobota" } }; - yield return new object[] { "de-AT", new string[] { "Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag" } }; - yield return new object[] { "el-GR", new string[] { "Κυριακή", "Δευτέρα", "Τρίτη", "Τετάρτη", "Πέμπτη", "Παρασκευή", "Σάββατο" } }; - yield return new object[] { "en-US", new string[] { "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" } }; - yield return new object[] { "es-419", new string[] { "domingo", "lunes", "martes", "miércoles", "jueves", "viernes", "sábado" } }; - yield return new object[] { "es-ES", new string[] { "domingo", "lunes", "martes", "miércoles", "jueves", "viernes", "sábado" } }; - yield return new object[] { "es-MX", new string[] { "domingo", "lunes", "martes", "miércoles", "jueves", "viernes", "sábado" } }; - yield return new object[] { "et-EE", new string[] { "pühapäev", "esmaspäev", "teisipäev", "kolmapäev", "neljapäev", "reede", "laupäev" } }; - yield return new object[] { "fa-IR", new string[] { "یکشنبه", "دوشنبه", "سه‌شنبه", "چهارشنبه", "پنجشنبه", "جمعه", "شنبه" } }; - yield return new object[] { "fi-FI", new string[] { "sunnuntai", "maanantai", "tiistai", "keskiviikko", "torstai", "perjantai", "lauantai" } }; - yield return new object[] { "fil-PH", new string[] { "Linggo", "Lunes", "Martes", "Miyerkules", "Huwebes", "Biyernes", "Sabado" } }; - yield return new object[] { "fr-FR", new string[] { "dimanche", "lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi" } }; - yield return new object[] { "gu-IN", new string[] { "રવિવાર", "સોમવાર", "મંગળવાર", "બુધવાર", "ગુરુવાર", "શુક્રવાર", "શનિવાર" } }; - yield return new object[] { "he-IL", new string[] { "יום ראשון", "יום שני", "יום שלישי", "יום רביעי", "יום חמישי", "יום שישי", "יום שבת" } }; - yield return new object[] { "hi-IN", new string[] { "रविवार", "सोमवार", "मंगलवार", "बुधवार", "गुरुवार", "शुक्रवार", "शनिवार" } }; - yield return new object[] { "hr-HR", new string[] { "nedjelja", "ponedjeljak", "utorak", "srijeda", "četvrtak", "petak", "subota" } }; - yield return new object[] { "hu-HU", new string[] { "vasárnap", "hétfő", "kedd", "szerda", "csütörtök", "péntek", "szombat" } }; - yield return new object[] { "id-ID", new string[] { "Minggu", "Senin", "Selasa", "Rabu", "Kamis", "Jumat", "Sabtu" } }; - yield return new object[] { "it-IT", new string[] { "domenica", "lunedì", "martedì", "mercoledì", "giovedì", "venerdì", "sabato" } }; - yield return new object[] { "ja-JP", new string[] { "日曜日", "月曜日", "火曜日", "水曜日", "木曜日", "金曜日", "土曜日" } }; - yield return new object[] { "kn-IN", new string[] { "ಭಾನುವಾರ", "ಸೋಮವಾರ", "ಮಂಗಳವಾರ", "ಬುಧವಾರ", "ಗುರುವಾರ", "ಶುಕ್ರವಾರ", "ಶನಿವಾರ" } }; - yield return new object[] { "ko-KR", new string[] { "일요일", "월요일", "화요일", "수요일", "목요일", "금요일", "토요일" } }; - yield return new object[] { "lt-LT", new string[] { "sekmadienis", "pirmadienis", "antradienis", "trečiadienis", "ketvirtadienis", "penktadienis", "šeštadienis" } }; - yield return new object[] { "lv-LV", new string[] { "Svētdiena", "Pirmdiena", "Otrdiena", "Trešdiena", "Ceturtdiena", "Piektdiena", "Sestdiena" } }; - yield return new object[] { "ml-IN", new string[] { "ഞായറാഴ്‌ച", "തിങ്കളാഴ്‌ച", "ചൊവ്വാഴ്‌ച", "ബുധനാഴ്‌ച", "വ്യാഴാഴ്‌ച", "വെള്ളിയാഴ്‌ച", "ശനിയാഴ്‌ച" } }; - yield return new object[] { "ms-BN", new string[] { "Ahad", "Isnin", "Selasa", "Rabu", "Khamis", "Jumaat", "Sabtu" } }; - yield return new object[] { "no-NO", new string[] { "søndag", "mandag", "tirsdag", "onsdag", "torsdag", "fredag", "lørdag" } }; - yield return new object[] { "nl-AW", new string[] { "zondag", "maandag", "dinsdag", "woensdag", "donderdag", "vrijdag", "zaterdag" } }; - yield return new object[] { "pl-PL", new string[] { "niedziela", "poniedziałek", "wtorek", "środa", "czwartek", "piątek", "sobota" } }; - yield return new object[] { "pt-PT", new string[] { "domingo", "segunda-feira", "terça-feira", "quarta-feira", "quinta-feira", "sexta-feira", "sábado" } }; - yield return new object[] { "ro-RO", new string[] { "duminică", "luni", "marți", "miercuri", "joi", "vineri", "sâmbătă" } }; - yield return new object[] { "sk-SK", new string[] { "nedeľa", "pondelok", "utorok", "streda", "štvrtok", "piatok", "sobota" } }; - yield return new object[] { "sv-AX", new string[] { "söndag", "måndag", "tisdag", "onsdag", "torsdag", "fredag", "lördag" } }; - yield return new object[] { "sw-CD", new string[] { "Jumapili", "Jumatatu", "Jumanne", "Jumatano", "Alhamisi", "Ijumaa", "Jumamosi" } }; - yield return new object[] { "ta-IN", new string[] { "ஞாயிறு", "திங்கள்", "செவ்வாய்", "புதன்", "வியாழன்", "வெள்ளி", "சனி" } }; - yield return new object[] { "te-IN", new string[] { "ఆదివారం", "సోమవారం", "మంగళవారం", "బుధవారం", "గురువారం", "శుక్రవారం", "శనివారం" } }; - yield return new object[] { "th-TH", new string[] { "วันอาทิตย์", "วันจันทร์", "วันอังคาร", "วันพุธ", "วันพฤหัสบดี", "วันศุกร์", "วันเสาร์" } }; - yield return new object[] { "tr-CY", new string[] { "Pazar", "Pazartesi", "Salı", "Çarşamba", "Perşembe", "Cuma", "Cumartesi" } }; - yield return new object[] { "uk-UA", new string[] { "неділя", "понеділок", "вівторок", "середа", "четвер", "пʼятниця", "субота" } }; - yield return new object[] { "vi-VN", new string[] { "Chủ Nhật", "Thứ Hai", "Thứ Ba", "Thứ Tư", "Thứ Năm", "Thứ Sáu", "Thứ Bảy" } }; - yield return new object[] { "zh-TW", new string[] { "星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六" } }; - } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(DayNames_Get_TestData_ICU))] public void DayNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string[] expected) @@ -91,17 +41,6 @@ public void DayNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string[] Assert.Equal(expected, format.DayNames); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(DayNames_Get_TestData_HybridGlobalization))] - public void DayNames_Get_ReturnsExpected_HybridGlobalization(string cultureName, string[] expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - int length = format.DayNames.Length; - Assert.True(length == expected.Length, $"Length comparison failed for culture: {cultureName}. Expected: {expected.Length}, Actual: {length}"); - for (int i = 0; i FirstDayOfWeek_Get_TestData() yield return new object[] { new CultureInfo("fr-FR", false).DateTimeFormat, DayOfWeek.Monday, "fr-FR" }; } - public static IEnumerable FirstDayOfWeek_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", DayOfWeek.Sunday }; - yield return new object[] { "am-ET", DayOfWeek.Sunday }; - yield return new object[] { "bg-BG", DayOfWeek.Monday }; - yield return new object[] { "bn-BD", DayOfWeek.Sunday }; - yield return new object[] { "bn-IN", DayOfWeek.Sunday }; - yield return new object[] { "ca-AD", DayOfWeek.Monday }; - yield return new object[] { "ca-ES", DayOfWeek.Monday }; - yield return new object[] { "cs-CZ", DayOfWeek.Monday }; - yield return new object[] { "da-DK", DayOfWeek.Monday }; - yield return new object[] { "de-AT", DayOfWeek.Monday }; - yield return new object[] { "de-BE", DayOfWeek.Monday }; - yield return new object[] { "de-CH", DayOfWeek.Monday }; - yield return new object[] { "de-DE", DayOfWeek.Monday }; - yield return new object[] { "de-IT", DayOfWeek.Monday }; - yield return new object[] { "de-LI", DayOfWeek.Monday }; - yield return new object[] { "de-LU", DayOfWeek.Monday }; - yield return new object[] { "el-CY", DayOfWeek.Monday }; - yield return new object[] { "el-GR", DayOfWeek.Monday }; - yield return new object[] { "en-AE", DayOfWeek.Saturday }; - yield return new object[] { "en-AG", DayOfWeek.Sunday }; - yield return new object[] { "en-AI", DayOfWeek.Monday }; - yield return new object[] { "en-AS", DayOfWeek.Sunday }; - yield return new object[] { "en-AT", DayOfWeek.Monday }; - yield return new object[] { "en-AU", DayOfWeek.Monday }; // originally in ICU: Sunday, even though ISO 8601 states: Monday - yield return new object[] { "en-BB", DayOfWeek.Monday }; - yield return new object[] { "en-BE", DayOfWeek.Monday }; - yield return new object[] { "en-BI", DayOfWeek.Monday }; - yield return new object[] { "en-BM", DayOfWeek.Monday }; - yield return new object[] { "en-BS", DayOfWeek.Sunday }; - yield return new object[] { "en-BW", DayOfWeek.Sunday }; - yield return new object[] { "en-BZ", DayOfWeek.Sunday }; - yield return new object[] { "en-CA", DayOfWeek.Sunday }; - yield return new object[] { "en-CC", DayOfWeek.Monday }; - yield return new object[] { "en-CH", DayOfWeek.Monday }; - yield return new object[] { "en-CK", DayOfWeek.Monday }; - yield return new object[] { "en-CM", DayOfWeek.Monday }; - yield return new object[] { "en-CX", DayOfWeek.Monday }; - yield return new object[] { "en-CY", DayOfWeek.Monday }; - yield return new object[] { "en-DE", DayOfWeek.Monday }; - yield return new object[] { "en-DK", DayOfWeek.Monday }; - yield return new object[] { "en-DM", DayOfWeek.Sunday }; - yield return new object[] { "en-ER", DayOfWeek.Monday }; - yield return new object[] { "en-FI", DayOfWeek.Monday }; - yield return new object[] { "en-FJ", DayOfWeek.Monday }; - yield return new object[] { "en-FK", DayOfWeek.Monday }; - yield return new object[] { "en-FM", DayOfWeek.Monday }; - yield return new object[] { "en-GB", DayOfWeek.Monday }; - yield return new object[] { "en-GD", DayOfWeek.Monday }; - yield return new object[] { "en-GG", DayOfWeek.Monday }; - yield return new object[] { "en-GH", DayOfWeek.Monday }; - yield return new object[] { "en-GI", DayOfWeek.Monday }; - yield return new object[] { "en-GM", DayOfWeek.Monday }; - yield return new object[] { "en-GU", DayOfWeek.Sunday }; - yield return new object[] { "en-GY", DayOfWeek.Monday }; - yield return new object[] { "en-HK", DayOfWeek.Sunday }; - yield return new object[] { "en-IE", DayOfWeek.Monday }; - yield return new object[] { "en-IL", DayOfWeek.Sunday }; - yield return new object[] { "en-IM", DayOfWeek.Monday }; - yield return new object[] { "en-IN", DayOfWeek.Sunday }; - yield return new object[] { "en-IO", DayOfWeek.Monday }; - yield return new object[] { "en-JE", DayOfWeek.Monday }; - yield return new object[] { "en-JM", DayOfWeek.Sunday }; - yield return new object[] { "en-KE", DayOfWeek.Sunday }; - yield return new object[] { "en-KI", DayOfWeek.Monday }; - yield return new object[] { "en-KN", DayOfWeek.Monday }; - yield return new object[] { "en-KY", DayOfWeek.Monday }; - yield return new object[] { "en-LC", DayOfWeek.Monday }; - yield return new object[] { "en-LR", DayOfWeek.Monday }; - yield return new object[] { "en-LS", DayOfWeek.Monday }; - yield return new object[] { "en-MG", DayOfWeek.Monday }; - yield return new object[] { "en-MH", DayOfWeek.Sunday }; - yield return new object[] { "en-MO", DayOfWeek.Sunday }; - yield return new object[] { "en-MP", DayOfWeek.Monday }; - yield return new object[] { "en-MS", DayOfWeek.Monday }; - yield return new object[] { "en-MT", DayOfWeek.Sunday }; - yield return new object[] { "en-MU", DayOfWeek.Monday }; - yield return new object[] { "en-MW", DayOfWeek.Monday }; - yield return new object[] { "en-MY", DayOfWeek.Monday }; - yield return new object[] { "en-NA", DayOfWeek.Monday }; - yield return new object[] { "en-NF", DayOfWeek.Monday }; - yield return new object[] { "en-NG", DayOfWeek.Monday }; - yield return new object[] { "en-NL", DayOfWeek.Monday }; - yield return new object[] { "en-NR", DayOfWeek.Monday }; - yield return new object[] { "en-NU", DayOfWeek.Monday }; - yield return new object[] { "en-NZ", DayOfWeek.Monday }; - yield return new object[] { "en-PG", DayOfWeek.Monday }; - yield return new object[] { "en-PH", DayOfWeek.Sunday }; - yield return new object[] { "en-PK", DayOfWeek.Sunday }; - yield return new object[] { "en-PN", DayOfWeek.Monday }; - yield return new object[] { "en-PR", DayOfWeek.Sunday }; - yield return new object[] { "en-PW", DayOfWeek.Monday }; - yield return new object[] { "en-RW", DayOfWeek.Monday }; - yield return new object[] { "en-SB", DayOfWeek.Monday }; - yield return new object[] { "en-SC", DayOfWeek.Monday }; - yield return new object[] { "en-SD", DayOfWeek.Saturday }; - yield return new object[] { "en-SE", DayOfWeek.Monday }; - yield return new object[] { "en-SG", DayOfWeek.Sunday }; - yield return new object[] { "en-SH", DayOfWeek.Monday }; - yield return new object[] { "en-SI", DayOfWeek.Monday }; - yield return new object[] { "en-SL", DayOfWeek.Monday }; - yield return new object[] { "en-SS", DayOfWeek.Monday }; - yield return new object[] { "en-SX", DayOfWeek.Monday }; - yield return new object[] { "en-SZ", DayOfWeek.Monday }; - yield return new object[] { "en-TC", DayOfWeek.Monday }; - yield return new object[] { "en-TK", DayOfWeek.Monday }; - yield return new object[] { "en-TO", DayOfWeek.Monday }; - yield return new object[] { "en-TT", DayOfWeek.Sunday }; - yield return new object[] { "en-TV", DayOfWeek.Monday }; - yield return new object[] { "en-TZ", DayOfWeek.Monday }; - yield return new object[] { "en-UG", DayOfWeek.Monday }; - yield return new object[] { "en-UM", DayOfWeek.Sunday }; - yield return new object[] { "en-VC", DayOfWeek.Monday }; - yield return new object[] { "en-VG", DayOfWeek.Monday }; - yield return new object[] { "en-VI", DayOfWeek.Sunday }; - yield return new object[] { "en-VU", DayOfWeek.Monday }; - yield return new object[] { "en-WS", DayOfWeek.Sunday }; - yield return new object[] { "en-ZA", DayOfWeek.Sunday }; - yield return new object[] { "en-ZM", DayOfWeek.Monday }; - yield return new object[] { "en-ZW", DayOfWeek.Sunday }; - yield return new object[] { "en-US", DayOfWeek.Sunday }; - yield return new object[] { "es-419", DayOfWeek.Monday }; - yield return new object[] { "es-ES", DayOfWeek.Monday }; - yield return new object[] { "es-MX", DayOfWeek.Sunday }; - yield return new object[] { "et-EE", DayOfWeek.Monday }; - yield return new object[] { "fa-IR", DayOfWeek.Saturday }; - yield return new object[] { "fi-FI", DayOfWeek.Monday }; - yield return new object[] { "fil-PH", DayOfWeek.Sunday }; - yield return new object[] { "fr-BE", DayOfWeek.Monday }; - yield return new object[] { "fr-CA", DayOfWeek.Sunday }; - yield return new object[] { "fr-CH", DayOfWeek.Monday }; - yield return new object[] { "fr-FR", DayOfWeek.Monday }; - yield return new object[] { "gu-IN", DayOfWeek.Sunday }; - yield return new object[] { "he-IL", DayOfWeek.Sunday }; - yield return new object[] { "hi-IN", DayOfWeek.Sunday }; - yield return new object[] { "hr-BA", DayOfWeek.Monday }; - yield return new object[] { "hr-HR", DayOfWeek.Monday }; - yield return new object[] { "hu-HU", DayOfWeek.Monday }; - yield return new object[] { "id-ID", DayOfWeek.Sunday }; - yield return new object[] { "it-CH", DayOfWeek.Monday }; - yield return new object[] { "it-IT", DayOfWeek.Monday }; - yield return new object[] { "ja-JP", DayOfWeek.Sunday }; - yield return new object[] { "kn-IN", DayOfWeek.Sunday }; - yield return new object[] { "ko-KR", DayOfWeek.Sunday }; - yield return new object[] { "lt-LT", DayOfWeek.Monday }; - yield return new object[] { "lv-LV", DayOfWeek.Monday }; - yield return new object[] { "ml-IN", DayOfWeek.Sunday }; - yield return new object[] { "mr-IN", DayOfWeek.Sunday }; - yield return new object[] { "ms-BN", DayOfWeek.Monday }; - yield return new object[] { "ms-MY", DayOfWeek.Monday }; - yield return new object[] { "ms-SG", DayOfWeek.Sunday }; - yield return new object[] { "nb-NO", DayOfWeek.Monday }; - yield return new object[] { "no", DayOfWeek.Monday }; - yield return new object[] { "no-NO", DayOfWeek.Monday }; - yield return new object[] { "nl-AW", DayOfWeek.Monday }; - yield return new object[] { "nl-BE", DayOfWeek.Monday }; - yield return new object[] { "nl-NL", DayOfWeek.Monday }; - yield return new object[] { "pl-PL", DayOfWeek.Monday }; - yield return new object[] { "pt-BR", DayOfWeek.Sunday }; - yield return new object[] { "pt-PT", DayOfWeek.Sunday }; - yield return new object[] { "ro-RO", DayOfWeek.Monday }; - yield return new object[] { "ru-RU", DayOfWeek.Monday }; - yield return new object[] { "sk-SK", DayOfWeek.Monday }; - yield return new object[] { "sl-SI", DayOfWeek.Monday }; - yield return new object[] { "sr-Cyrl-RS", DayOfWeek.Monday }; - yield return new object[] { "sr-Latn-RS", DayOfWeek.Monday }; - yield return new object[] { "sv-AX", DayOfWeek.Monday }; - yield return new object[] { "sv-SE", DayOfWeek.Monday }; - yield return new object[] { "sw-CD", DayOfWeek.Monday }; - yield return new object[] { "sw-KE", DayOfWeek.Sunday }; - yield return new object[] { "sw-TZ", DayOfWeek.Monday }; - yield return new object[] { "sw-UG", DayOfWeek.Monday }; - yield return new object[] { "ta-IN", DayOfWeek.Sunday }; - yield return new object[] { "ta-LK", DayOfWeek.Monday }; - yield return new object[] { "ta-MY", DayOfWeek.Monday }; - yield return new object[] { "ta-SG", DayOfWeek.Sunday }; - yield return new object[] { "te-IN", DayOfWeek.Sunday }; - yield return new object[] { "th-TH", DayOfWeek.Sunday }; - yield return new object[] { "tr-CY", DayOfWeek.Monday }; - yield return new object[] { "tr-TR", DayOfWeek.Monday }; - yield return new object[] { "uk-UA", DayOfWeek.Monday }; - yield return new object[] { "vi-VN", DayOfWeek.Monday }; - yield return new object[] { "zh-CN", DayOfWeek.Monday }; - yield return new object[] { "zh-Hans-HK", DayOfWeek.Sunday }; - yield return new object[] { "zh-SG", DayOfWeek.Sunday }; - yield return new object[] { "zh-HK", DayOfWeek.Sunday }; - yield return new object[] { "zh-TW", DayOfWeek.Sunday }; - } - [Theory] [MemberData(nameof(FirstDayOfWeek_Get_TestData))] public void FirstDayOfWeek(DateTimeFormatInfo format, DayOfWeek expected, string cultureName) @@ -213,14 +22,6 @@ public void FirstDayOfWeek(DateTimeFormatInfo format, DayOfWeek expected, string Assert.True(expected == format.FirstDayOfWeek, $"Failed for culture: {cultureName}. Expected: {expected}, Actual: {format.FirstDayOfWeek}"); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(FirstDayOfWeek_Get_TestData_HybridGlobalization))] - public void FirstDayOfWeekHybridGlobalization(string culture, DayOfWeek expected) - { - DateTimeFormatInfo format = new CultureInfo(culture).DateTimeFormat; - FirstDayOfWeek(format, expected, culture); - } - [Theory] [InlineData(DayOfWeek.Sunday)] [InlineData(DayOfWeek.Monday)] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoFullDateTimePattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoFullDateTimePattern.cs index f84360d35dee9..fa95f52530426 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoFullDateTimePattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoFullDateTimePattern.cs @@ -24,204 +24,6 @@ public static IEnumerable FullDateTimePattern_Set_TestData() yield return new object[] { "HH:mm:ss dddd, dd MMMM yyyy" }; } - public static IEnumerable FullDateTimePattern_Get_TestData_HybridGlobalization() - { - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "dddd، d MMMM yyyy h:mm:ss tt" }; // dddd، d MMMM yyyy g h:mm:ss tt - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, "yyyy MMMM d, dddd h:mm:ss tt" }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM yyyy 'г'. H:mm:ss ч." : "dddd, d MMMM yyyy 'г'. H:mm:ss" }; // dddd, d MMMM yyyy 'г'. H:mm:ss - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, "dddd, d MMMM, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, "dddd, d MMMM, yyyy h:mm:ss tt" }; - string catalanPattern = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d 'de' MMMM 'de' yyyy H:mm:ss" : "dddd, d 'de' MMMM 'del' yyyy H:mm:ss"; // dddd, d MMMM 'de' yyyy H:mm:ss - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, catalanPattern }; - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, catalanPattern }; - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, "dddd d. MMMM yyyy H:mm:ss" }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, "dddd 'den' d. MMMM yyyy HH.mm.ss" }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, "dddd d MMMM yyyy h:mm:ss tt" }; // dddd, d MMMM yyyy h:mm:ss tt - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, "dddd d MMMM yyyy h:mm:ss tt" }; // dddd, d MMMM yyyy h:mm:ss tt - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM yyyy h:mm:ss tt" : "dddd d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, "dddd, MMMM d, yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; // dddd, dd MMMM yyyy HH:mm:ss - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; // dddd, dd MMMM yyyy HH:mm:ss - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, "dddd, d MMMM yyyy HH.mm.ss" }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, "dddd, d MMMM yyyy H.mm.ss" }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM yyyy HH:mm:ss" : "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, "dddd, d MMMM yyyy H:mm:ss" }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM, yyyy h:mm:ss tt" : "dddd d MMMM, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; // dddd, d MMMM yyyy h:mm:ss tt - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; // dddd, dd MMMM yyyy HH:mm:ss - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; // dddd, dd MMMM yyyy HH:mm:ss - string latinAmericaSpanishFormat = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d 'de' MMMM 'de' yyyy HH:mm:ss" : "dddd, d 'de' MMMM 'de' yyyy h:mm:ss tt"; // dddd, d 'de' MMMM 'de' yyyy HH:mm:ss - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, latinAmericaSpanishFormat }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "dddd, d 'de' MMMM 'de' yyyy H:mm:ss" }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, latinAmericaSpanishFormat }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "yyyy MMMM d, dddd H:mm:ss" }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, "dddd d. MMMM yyyy H.mm.ss" }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, "dddd, MMMM d, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, "dddd d MMMM yyyy HH 'h' mm 'min' ss 's'" }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, "dddd, d MMMM, yyyy hh:mm:ss tt" }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, "dddd, d בMMMM yyyy H:mm:ss" }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, "dddd, d. MMMM yyyy. HH:mm:ss" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "dddd, d. MMMM yyyy. HH:mm:ss" }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "yyyy. MMMM d., dddd H:mm:ss" }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, "dddd, d MMMM yyyy HH.mm.ss" }; // dddd, dd MMMM yyyy HH.mm.ss - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "yyyy年M月d日dddd H:mm:ss" }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, "dddd, MMMM d, yyyy hh:mm:ss tt" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "yyyy년 M월 d일 dddd tt h:mm:ss" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "yyyy 'm'. MMMM d 'd'., dddd HH:mm:ss" }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "dddd, yyyy. 'gada' d. MMMM HH:mm:ss" }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "yyyy, MMMM d, dddd h:mm:ss tt" }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, "dddd, d MMMM, yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; // dd MMMM yyyy h:mm:ss tt - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, "dddd, d MMMM yyyy h:mm:ss tt" }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, "dddd d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, "dddd d. MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, "dddd, d 'de' MMMM 'de' yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "dddd, d 'de' MMMM 'de' yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "dddd, d MMMM yyyy 'г'. HH:mm:ss" }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, "dddd d. MMMM yyyy H:mm:ss" }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, "dddd, d. MMMM yyyy HH:mm:ss" }; // dddd, dd. MMMM yyyy HH:mm:ss - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, "dddd, d. MMMM yyyy. HH:mm:ss" }; // dddd, dd. MMMM yyyy. HH:mm:ss - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "dddd, d. MMMM yyyy. HH:mm:ss" }; // dddd, dd. MMMM yyyy. HH:mm:ss - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, "dddd d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, "dddd, d MMMM yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, "dddd, d MMMM, yyyy tt h:mm:ss" }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, "dddd, d MMMM, yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, "dddd, d MMMM, yyyy tt h:mm:ss" }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, "dddd, d MMMM, yyyy tt h:mm:ss" }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, "d, MMMM yyyy, dddd h:mm:ss tt" }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, "ddddที่ d MMMM g yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, "d MMMM yyyy dddd h:mm:ss tt" }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, "d MMMM yyyy dddd HH:mm:ss" }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, "dddd, d MMMM yyyy 'р'. HH:mm:ss" }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "dddd, d MMMM, yyyy HH:mm:ss" }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, "yyyy年M月d日dddd HH:mm:ss" }; // yyyy年M月d日dddd tth:mm:ss - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, "yyyy年M月d日dddd tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, "yyyy年M月d日dddd tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, "yyyy年M月d日dddd tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "yyyy年M月d日 dddd tth:mm:ss" }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(FullDateTimePattern_Get_TestData_HybridGlobalization))] - public void FullDateTimePattern_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string value) - { - Assert.Equal(value, format.FullDateTimePattern); - } - [Theory] [MemberData(nameof(FullDateTimePattern_Set_TestData))] public void FullDateTimePattern_Set_GetReturnsExpected(string value) diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetAbbreviatedEraName.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetAbbreviatedEraName.cs index 18de097fff17e..bff773b9038c2 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetAbbreviatedEraName.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetAbbreviatedEraName.cs @@ -15,197 +15,6 @@ public static IEnumerable GetAbbreviatedEraName_TestData() yield return new object[] { "invariant", 0, "AD" }; yield return new object[] { "invariant", 1, "AD" }; yield return new object[] { "ja-JP", 1, DateTimeFormatInfoData.JaJPAbbreviatedEraName() }; - - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", 1, "هـ" }; - yield return new object[] { "am-ET", 1, "ዓ/ም" }; - yield return new object[] { "bg-BG", 1, "сл.Хр." }; - yield return new object[] { "bn-BD", 1, "খৃষ্টাব্দ" }; - yield return new object[] { "bn-IN", 1, "খ্রিঃ" }; // "খৃষ্টাব্দ" - yield return new object[] { "ca-AD", 1, "dC" }; - yield return new object[] { "ca-ES", 1, "dC" }; - yield return new object[] { "cs-CZ", 1, "n.l." }; - yield return new object[] { "da-DK", 1, "eKr" }; - yield return new object[] { "de-AT", 1, "n. Chr." }; - yield return new object[] { "de-BE", 1, "n. Chr." }; - yield return new object[] { "de-CH", 1, "n. Chr." }; - yield return new object[] { "de-DE", 1, "n. Chr." }; - yield return new object[] { "de-IT", 1, "n. Chr." }; - yield return new object[] { "de-LI", 1, "n. Chr." }; - yield return new object[] { "de-LU", 1, "n. Chr." }; - yield return new object[] { "el-CY", 1, "μ.Χ." }; - yield return new object[] { "el-GR", 1, "μ.Χ." }; - yield return new object[] { "en-AE", 1, "A" }; // AD - yield return new object[] { "en-AG", 1, "A" }; // AD - yield return new object[] { "en-AI", 1, "A" }; // AD - yield return new object[] { "en-AS", 1, "A" }; - yield return new object[] { "en-AT", 1, "A" }; // AD - yield return new object[] { "en-AU", 1, "A" }; // AD - yield return new object[] { "en-BB", 1, "A" }; // AD - yield return new object[] { "en-BE", 1, "A" }; // AD - yield return new object[] { "en-BI", 1, "A" }; // AD - yield return new object[] { "en-BM", 1, "A" }; // AD - yield return new object[] { "en-BS", 1, "A" }; // AD - yield return new object[] { "en-BW", 1, "A" }; // AD - yield return new object[] { "en-BZ", 1, "A" }; // AD - yield return new object[] { "en-CA", 1, "A" }; // AD - yield return new object[] { "en-CC", 1, "A" }; // AD - yield return new object[] { "en-CH", 1, "A" }; // AD - yield return new object[] { "en-CK", 1, "A" }; // AD - yield return new object[] { "en-CM", 1, "A" }; // AD - yield return new object[] { "en-CX", 1, "A" }; // AD - yield return new object[] { "en-CY", 1, "A" }; // AD - yield return new object[] { "en-DE", 1, "A" }; // AD - yield return new object[] { "en-DK", 1, "A" }; // AD - yield return new object[] { "en-DM", 1, "A" }; // AD - yield return new object[] { "en-ER", 1, "A" }; // AD - yield return new object[] { "en-FI", 1, "A" }; // AD - yield return new object[] { "en-FJ", 1, "A" }; // AD - yield return new object[] { "en-FK", 1, "A" }; // AD - yield return new object[] { "en-FM", 1, "A" }; // AD - yield return new object[] { "en-GB", 1, "A" }; // AD - yield return new object[] { "en-GD", 1, "A" }; // AD - yield return new object[] { "en-GG", 1, "A" }; // AD - yield return new object[] { "en-GH", 1, "A" }; // AD - yield return new object[] { "en-GI", 1, "A" }; // AD - yield return new object[] { "en-GM", 1, "A" }; // AD - yield return new object[] { "en-GU", 1, "A" }; - yield return new object[] { "en-GY", 1, "A" }; // AD - yield return new object[] { "en-HK", 1, "A" }; // AD - yield return new object[] { "en-IE", 1, "A" }; // AD - yield return new object[] { "en-IL", 1, "A" }; // AD - yield return new object[] { "en-IM", 1, "A" }; // AD - yield return new object[] { "en-IN", 1, "A" }; // AD - yield return new object[] { "en-IO", 1, "A" }; // AD - yield return new object[] { "en-JE", 1, "A" }; // AD - yield return new object[] { "en-JM", 1, "A" }; // AD - yield return new object[] { "en-KE", 1, "A" }; // AD - yield return new object[] { "en-KI", 1, "A" }; // AD - yield return new object[] { "en-KN", 1, "A" }; // AD - yield return new object[] { "en-KY", 1, "A" }; // AD - yield return new object[] { "en-LC", 1, "A" }; // AD - yield return new object[] { "en-LR", 1, "A" }; // AD - yield return new object[] { "en-LS", 1, "A" }; // AD - yield return new object[] { "en-MG", 1, "A" }; // AD - yield return new object[] { "en-MH", 1, "A" }; - yield return new object[] { "en-MO", 1, "A" }; // AD - yield return new object[] { "en-MP", 1, "A" }; - yield return new object[] { "en-MS", 1, "A" }; // AD - yield return new object[] { "en-MT", 1, "A" }; // AD - yield return new object[] { "en-MU", 1, "A" }; // AD - yield return new object[] { "en-MW", 1, "A" }; // AD - yield return new object[] { "en-MY", 1, "A" }; // AD - yield return new object[] { "en-NA", 1, "A" }; // AD - yield return new object[] { "en-NF", 1, "A" }; // AD - yield return new object[] { "en-NG", 1, "A" }; // AD - yield return new object[] { "en-NL", 1, "A" }; // AD - yield return new object[] { "en-NR", 1, "A" }; // AD - yield return new object[] { "en-NU", 1, "A" }; // AD - yield return new object[] { "en-NZ", 1, "A" }; // AD - yield return new object[] { "en-PG", 1, "A" }; // AD - yield return new object[] { "en-PH", 1, "A" }; // AD - yield return new object[] { "en-PK", 1, "A" }; // AD - yield return new object[] { "en-PN", 1, "A" }; // AD - yield return new object[] { "en-PR", 1, "A" }; - yield return new object[] { "en-PW", 1, "A" }; // AD - yield return new object[] { "en-RW", 1, "A" }; // AD - yield return new object[] { "en-SB", 1, "A" }; // AD - yield return new object[] { "en-SC", 1, "A" }; // AD - yield return new object[] { "en-SD", 1, "A" }; // AD - yield return new object[] { "en-SE", 1, "A" }; // AD - yield return new object[] { "en-SG", 1, "A" }; // AD - yield return new object[] { "en-SH", 1, "A" }; // AD - yield return new object[] { "en-SI", 1, "A" }; // AD - yield return new object[] { "en-SL", 1, "A" }; // AD - yield return new object[] { "en-SS", 1, "A" }; // AD - yield return new object[] { "en-SX", 1, "A" }; // AD - yield return new object[] { "en-SZ", 1, "A" }; // AD - yield return new object[] { "en-TC", 1, "A" }; // AD - yield return new object[] { "en-TK", 1, "A" }; // AD - yield return new object[] { "en-TO", 1, "A" }; // AD - yield return new object[] { "en-TT", 1, "A" }; // AD - yield return new object[] { "en-TV", 1, "A" }; // AD - yield return new object[] { "en-TZ", 1, "A" }; // AD - yield return new object[] { "en-UG", 1, "A" }; // AD - yield return new object[] { "en-UM", 1, "A" }; - yield return new object[] { "en-US", 1, "A" }; - yield return new object[] { "en-VC", 1, "A" }; // AD - yield return new object[] { "en-VG", 1, "A" }; // AD - yield return new object[] { "en-VI", 1, "A" }; - yield return new object[] { "en-VU", 1, "A" }; // AD - yield return new object[] { "en-WS", 1, "A" }; // AD - yield return new object[] { "en-ZA", 1, "A" }; // AD - yield return new object[] { "en-ZM", 1, "A" }; // AD - yield return new object[] { "en-ZW", 1, "A" }; // AD - yield return new object[] { "es-ES", 1, "d. C." }; - yield return new object[] { "es-419", 1, "d.C." }; // "d. C." - yield return new object[] { "es-MX", 1, "d.C." }; // "d. C." - yield return new object[] { "et-EE", 1, "pKr" }; - yield return new object[] { "fa-IR", 1, "ه.ش" }; // ه‍.ش. - yield return new object[] { "fi-FI", 1, "jKr" }; - yield return new object[] { "fil-PH", 1, "AD" }; - yield return new object[] { "fr-BE", 1, "ap. J.-C." }; - yield return new object[] { "fr-CA", 1, "ap. J.-C." }; - yield return new object[] { "fr-CH", 1, "ap. J.-C." }; - yield return new object[] { "fr-FR", 1, "ap. J.-C." }; - yield return new object[] { "gu-IN", 1, "ઇસ" }; - yield return new object[] { "he-IL", 1, "אחריי" }; // לספירה - yield return new object[] { "hi-IN", 1, "ईस्वी" }; - yield return new object[] { "hr-BA", 1, "AD" }; // po. Kr. - yield return new object[] { "hr-HR", 1, "AD" }; - yield return new object[] { "hu-HU", 1, "isz." }; - yield return new object[] { "id-ID", 1, "M" }; - yield return new object[] { "it-CH", 1, "dC" }; // d.C. - yield return new object[] { "it-IT", 1, "dC" }; - yield return new object[] { "ja-JP", 1, "AD" }; - yield return new object[] { "kn-IN", 1, "ಕ್ರಿ.ಶ" }; - yield return new object[] { "ko-KR", 1, "AD" }; - yield return new object[] { "lt-LT", 1, "po Kr." }; - yield return new object[] { "lv-LV", 1, "m.ē." }; - yield return new object[] { "ml-IN", 1, "എഡി" }; - yield return new object[] { "mr-IN", 1, "इ. स." }; - yield return new object[] { "ms-BN", 1, "TM" }; - yield return new object[] { "ms-MY", 1, "TM" }; - yield return new object[] { "ms-SG", 1, "TM" }; - yield return new object[] { "nb-NO", 1, "e.Kr." }; - yield return new object[] { "no", 1, "e.Kr." }; - yield return new object[] { "no-NO", 1, "e.Kr." }; - yield return new object[] { "nl-AW", 1, "n.C." }; - yield return new object[] { "nl-BE", 1, "n.C." }; // n.Chr. - yield return new object[] { "nl-NL", 1, "n.C." }; - yield return new object[] { "pl-PL", 1, "n.e." }; - yield return new object[] { "pt-BR", 1, "d.C." }; - yield return new object[] { "pt-PT", 1, "d.C." }; - yield return new object[] { "ro-RO", 1, "d.Hr." }; - yield return new object[] { "ru-RU", 1, "н.э." }; - yield return new object[] { "sk-SK", 1, "po Kr." }; - yield return new object[] { "sl-SI", 1, "po Kr." }; - yield return new object[] { "sr-Cyrl-RS", 1, "н.е." }; - yield return new object[] { "sr-Latn-RS", 1, "n.e." }; - yield return new object[] { "sv-AX", 1, "e.Kr." }; - yield return new object[] { "sv-SE", 1, "e.Kr." }; - yield return new object[] { "sw-CD", 1, "BK" }; - yield return new object[] { "sw-KE", 1, "BK" }; - yield return new object[] { "sw-TZ", 1, "BK" }; - yield return new object[] { "sw-UG", 1, "BK" }; - yield return new object[] { "ta-IN", 1, "கி.பி." }; - yield return new object[] { "ta-LK", 1, "கி.பி." }; - yield return new object[] { "ta-MY", 1, "கி.பி." }; - yield return new object[] { "ta-SG", 1, "கி.பி." }; - yield return new object[] { "te-IN", 1, "క్రీశ" }; - yield return new object[] { "th-TH", 1, "พ.ศ." }; - yield return new object[] { "tr-CY", 1, "MS" }; - yield return new object[] { "tr-TR", 1, "MS" }; - yield return new object[] { "uk-UA", 1, "н.е." }; - yield return new object[] { "vi-VN", 1, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "sau CN" : "CN" }; // sau CN - yield return new object[] { "zh-CN", 1, "公元" }; - yield return new object[] { "zh-Hans-HK", 1, "公元" }; - yield return new object[] { "zh-SG", 1, "公元" }; - yield return new object[] { "zh-HK", 1, "公元" }; - yield return new object[] { "zh-TW", 1, "西元" }; - } } [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetEraName.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetEraName.cs index c007c7e11059a..dd47204ea5d2a 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetEraName.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoGetEraName.cs @@ -12,394 +12,10 @@ public static IEnumerable GetEraName_TestData() { yield return new object[] { "invariant", 1, "A.D." }; yield return new object[] { "invariant", 0, "A.D." }; - - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - var enUS = "en-US"; - yield return new object[] { enUS, 1, DateTimeFormatInfoData.EnUSEraName() }; - yield return new object[] { enUS, 0, DateTimeFormatInfoData.EnUSEraName() }; - - var frFR = "fr-FR"; - yield return new object[] { frFR, 1, "ap. J.-C." }; - yield return new object[] { frFR, 0, "ap. J.-C." }; - } - else - { - yield return new object[] { "ar-SA", 0, "بعد الهجرة" }; - yield return new object[] { "ar-SA", 1, "بعد الهجرة" }; - yield return new object[] { "am-ET", 0, "ዓ/ም" }; - yield return new object[] { "am-ET", 1, "ዓ/ም" }; - yield return new object[] { "bg-BG", 0, "сл.Хр." }; - yield return new object[] { "bg-BG", 1, "сл.Хр." }; - yield return new object[] { "bn-BD", 0, "খৃষ্টাব্দ" }; - yield return new object[] { "bn-BD", 1, "খৃষ্টাব্দ" }; - yield return new object[] { "bn-IN", 0, "খ্রিঃ" }; - yield return new object[] { "bn-IN", 1, "খ্রিঃ" }; - yield return new object[] { "ca-AD", 0, "dC" }; - yield return new object[] { "ca-AD", 1, "dC" }; - yield return new object[] { "ca-ES", 0, "dC" }; - yield return new object[] { "ca-ES", 1, "dC" }; - yield return new object[] { "cs-CZ", 0, "n. l." }; - yield return new object[] { "cs-CZ", 1, "n. l." }; - yield return new object[] { "da-DK", 0, "e.Kr." }; - yield return new object[] { "da-DK", 1, "e.Kr." }; - yield return new object[] { "de-AT", 0, "n. Chr." }; - yield return new object[] { "de-AT", 1, "n. Chr." }; - yield return new object[] { "de-BE", 0, "n. Chr." }; - yield return new object[] { "de-BE", 1, "n. Chr." }; - yield return new object[] { "de-CH", 0, "n. Chr." }; - yield return new object[] { "de-CH", 1, "n. Chr." }; - yield return new object[] { "de-DE", 0, "n. Chr." }; - yield return new object[] { "de-DE", 1, "n. Chr." }; - yield return new object[] { "de-IT", 0, "n. Chr." }; - yield return new object[] { "de-IT", 1, "n. Chr." }; - yield return new object[] { "de-LI", 0, "n. Chr." }; - yield return new object[] { "de-LI", 1, "n. Chr." }; - yield return new object[] { "de-LU", 0, "n. Chr." }; - yield return new object[] { "de-LU", 1, "n. Chr." }; - yield return new object[] { "el-CY", 0, "μ.Χ." }; - yield return new object[] { "el-CY", 1, "μ.Χ." }; - yield return new object[] { "el-GR", 0, "μ.Χ." }; - yield return new object[] { "el-GR", 1, "μ.Χ." }; - yield return new object[] { "en-AE", 0, "AD" }; - yield return new object[] { "en-AE", 1, "AD" }; - yield return new object[] { "en-AG", 0, "AD" }; - yield return new object[] { "en-AG", 1, "AD" }; - yield return new object[] { "en-AI", 0, "AD" }; - yield return new object[] { "en-AI", 1, "AD" }; - yield return new object[] { "en-AS", 0, "AD" }; - yield return new object[] { "en-AS", 1, "AD" }; - yield return new object[] { "en-AT", 0, "AD" }; - yield return new object[] { "en-AT", 1, "AD" }; - yield return new object[] { "en-AU", 0, "AD" }; - yield return new object[] { "en-AU", 1, "AD" }; - yield return new object[] { "en-BB", 0, "AD" }; - yield return new object[] { "en-BB", 1, "AD" }; - yield return new object[] { "en-BE", 0, "AD" }; - yield return new object[] { "en-BE", 1, "AD" }; - yield return new object[] { "en-BI", 0, "AD" }; - yield return new object[] { "en-BI", 1, "AD" }; - yield return new object[] { "en-BM", 0, "AD" }; - yield return new object[] { "en-BM", 1, "AD" }; - yield return new object[] { "en-BS", 0, "AD" }; - yield return new object[] { "en-BS", 1, "AD" }; - yield return new object[] { "en-BW", 0, "AD" }; - yield return new object[] { "en-BW", 1, "AD" }; - yield return new object[] { "en-BZ", 0, "AD" }; - yield return new object[] { "en-BZ", 1, "AD" }; - yield return new object[] { "en-CA", 0, "AD" }; - yield return new object[] { "en-CA", 1, "AD" }; - yield return new object[] { "en-CC", 0, "AD" }; - yield return new object[] { "en-CC", 1, "AD" }; - yield return new object[] { "en-CH", 0, "AD" }; - yield return new object[] { "en-CH", 1, "AD" }; - yield return new object[] { "en-CK", 0, "AD" }; - yield return new object[] { "en-CK", 1, "AD" }; - yield return new object[] { "en-CM", 0, "AD" }; - yield return new object[] { "en-CM", 1, "AD" }; - yield return new object[] { "en-CX", 0, "AD" }; - yield return new object[] { "en-CX", 1, "AD" }; - yield return new object[] { "en-CY", 0, "AD" }; - yield return new object[] { "en-CY", 1, "AD" }; - yield return new object[] { "en-DE", 0, "AD" }; - yield return new object[] { "en-DE", 1, "AD" }; - yield return new object[] { "en-DK", 0, "AD" }; - yield return new object[] { "en-DK", 1, "AD" }; - yield return new object[] { "en-DM", 0, "AD" }; - yield return new object[] { "en-DM", 1, "AD" }; - yield return new object[] { "en-ER", 0, "AD" }; - yield return new object[] { "en-ER", 1, "AD" }; - yield return new object[] { "en-FI", 0, "AD" }; - yield return new object[] { "en-FI", 1, "AD" }; - yield return new object[] { "en-FJ", 0, "AD" }; - yield return new object[] { "en-FJ", 1, "AD" }; - yield return new object[] { "en-FK", 0, "AD" }; - yield return new object[] { "en-FK", 1, "AD" }; - yield return new object[] { "en-FM", 0, "AD" }; - yield return new object[] { "en-FM", 1, "AD" }; - yield return new object[] { "en-GB", 0, "AD" }; - yield return new object[] { "en-GB", 1, "AD" }; - yield return new object[] { "en-GD", 0, "AD" }; - yield return new object[] { "en-GD", 1, "AD" }; - yield return new object[] { "en-GG", 0, "AD" }; - yield return new object[] { "en-GG", 1, "AD" }; - yield return new object[] { "en-GH", 0, "AD" }; - yield return new object[] { "en-GH", 1, "AD" }; - yield return new object[] { "en-GI", 0, "AD" }; - yield return new object[] { "en-GI", 1, "AD" }; - yield return new object[] { "en-GM", 0, "AD" }; - yield return new object[] { "en-GM", 1, "AD" }; - yield return new object[] { "en-GU", 0, "AD" }; - yield return new object[] { "en-GU", 1, "AD" }; - yield return new object[] { "en-GY", 0, "AD" }; - yield return new object[] { "en-GY", 1, "AD" }; - yield return new object[] { "en-HK", 0, "AD" }; - yield return new object[] { "en-HK", 1, "AD" }; - yield return new object[] { "en-IE", 0, "AD" }; - yield return new object[] { "en-IE", 1, "AD" }; - yield return new object[] { "en-IL", 0, "AD" }; - yield return new object[] { "en-IL", 1, "AD" }; - yield return new object[] { "en-IM", 0, "AD" }; - yield return new object[] { "en-IM", 1, "AD" }; - yield return new object[] { "en-IN", 0, "AD" }; - yield return new object[] { "en-IN", 1, "AD" }; - yield return new object[] { "en-IO", 0, "AD" }; - yield return new object[] { "en-IO", 1, "AD" }; - yield return new object[] { "en-JE", 0, "AD" }; - yield return new object[] { "en-JE", 1, "AD" }; - yield return new object[] { "en-JM", 0, "AD" }; - yield return new object[] { "en-JM", 1, "AD" }; - yield return new object[] { "en-KE", 0, "AD" }; - yield return new object[] { "en-KE", 1, "AD" }; - yield return new object[] { "en-KI", 0, "AD" }; - yield return new object[] { "en-KI", 1, "AD" }; - yield return new object[] { "en-KN", 0, "AD" }; - yield return new object[] { "en-KN", 1, "AD" }; - yield return new object[] { "en-KY", 0, "AD" }; - yield return new object[] { "en-KY", 1, "AD" }; - yield return new object[] { "en-LC", 0, "AD" }; - yield return new object[] { "en-LC", 1, "AD" }; - yield return new object[] { "en-LR", 0, "AD" }; - yield return new object[] { "en-LR", 1, "AD" }; - yield return new object[] { "en-LS", 0, "AD" }; - yield return new object[] { "en-LS", 1, "AD" }; - yield return new object[] { "en-MG", 0, "AD" }; - yield return new object[] { "en-MG", 1, "AD" }; - yield return new object[] { "en-MH", 0, "AD" }; - yield return new object[] { "en-MH", 1, "AD" }; - yield return new object[] { "en-MO", 0, "AD" }; - yield return new object[] { "en-MO", 1, "AD" }; - yield return new object[] { "en-MP", 0, "AD" }; - yield return new object[] { "en-MP", 1, "AD" }; - yield return new object[] { "en-MS", 0, "AD" }; - yield return new object[] { "en-MS", 1, "AD" }; - yield return new object[] { "en-MT", 0, "AD" }; - yield return new object[] { "en-MT", 1, "AD" }; - yield return new object[] { "en-MU", 0, "AD" }; - yield return new object[] { "en-MU", 1, "AD" }; - yield return new object[] { "en-MW", 0, "AD" }; - yield return new object[] { "en-MW", 1, "AD" }; - yield return new object[] { "en-MY", 0, "AD" }; - yield return new object[] { "en-MY", 1, "AD" }; - yield return new object[] { "en-NA", 0, "AD" }; - yield return new object[] { "en-NA", 1, "AD" }; - yield return new object[] { "en-NF", 0, "AD" }; - yield return new object[] { "en-NF", 1, "AD" }; - yield return new object[] { "en-NG", 0, "AD" }; - yield return new object[] { "en-NG", 1, "AD" }; - yield return new object[] { "en-NL", 0, "AD" }; - yield return new object[] { "en-NL", 1, "AD" }; - yield return new object[] { "en-NR", 0, "AD" }; - yield return new object[] { "en-NR", 1, "AD" }; - yield return new object[] { "en-NU", 0, "AD" }; - yield return new object[] { "en-NU", 1, "AD" }; - yield return new object[] { "en-NZ", 0, "AD" }; - yield return new object[] { "en-NZ", 1, "AD" }; - yield return new object[] { "en-PG", 0, "AD" }; - yield return new object[] { "en-PG", 1, "AD" }; - yield return new object[] { "en-PH", 0, "AD" }; - yield return new object[] { "en-PH", 1, "AD" }; - yield return new object[] { "en-PK", 0, "AD" }; - yield return new object[] { "en-PK", 1, "AD" }; - yield return new object[] { "en-PN", 0, "AD" }; - yield return new object[] { "en-PN", 1, "AD" }; - yield return new object[] { "en-PR", 0, "AD" }; - yield return new object[] { "en-PR", 1, "AD" }; - yield return new object[] { "en-PW", 0, "AD" }; - yield return new object[] { "en-PW", 1, "AD" }; - yield return new object[] { "en-RW", 0, "AD" }; - yield return new object[] { "en-RW", 1, "AD" }; - yield return new object[] { "en-SB", 0, "AD" }; - yield return new object[] { "en-SB", 1, "AD" }; - yield return new object[] { "en-SC", 0, "AD" }; - yield return new object[] { "en-SC", 1, "AD" }; - yield return new object[] { "en-SD", 0, "AD" }; - yield return new object[] { "en-SD", 1, "AD" }; - yield return new object[] { "en-SE", 0, "AD" }; - yield return new object[] { "en-SE", 1, "AD" }; - yield return new object[] { "en-SG", 0, "AD" }; - yield return new object[] { "en-SG", 1, "AD" }; - yield return new object[] { "en-SH", 0, "AD" }; - yield return new object[] { "en-SH", 1, "AD" }; - yield return new object[] { "en-SI", 0, "AD" }; - yield return new object[] { "en-SI", 1, "AD" }; - yield return new object[] { "en-SL", 0, "AD" }; - yield return new object[] { "en-SL", 1, "AD" }; - yield return new object[] { "en-SS", 0, "AD" }; - yield return new object[] { "en-SS", 1, "AD" }; - yield return new object[] { "en-SX", 0, "AD" }; - yield return new object[] { "en-SX", 1, "AD" }; - yield return new object[] { "en-SZ", 0, "AD" }; - yield return new object[] { "en-SZ", 1, "AD" }; - yield return new object[] { "en-TC", 0, "AD" }; - yield return new object[] { "en-TC", 1, "AD" }; - yield return new object[] { "en-TK", 0, "AD" }; - yield return new object[] { "en-TK", 1, "AD" }; - yield return new object[] { "en-TO", 0, "AD" }; - yield return new object[] { "en-TO", 1, "AD" }; - yield return new object[] { "en-TT", 0, "AD" }; - yield return new object[] { "en-TT", 1, "AD" }; - yield return new object[] { "en-TV", 0, "AD" }; - yield return new object[] { "en-TV", 1, "AD" }; - yield return new object[] { "en-TZ", 0, "AD" }; - yield return new object[] { "en-TZ", 1, "AD" }; - yield return new object[] { "en-UG", 0, "AD" }; - yield return new object[] { "en-UG", 1, "AD" }; - yield return new object[] { "en-UM", 0, "AD" }; - yield return new object[] { "en-UM", 1, "AD" }; - yield return new object[] { "en-US", 0, "AD" }; - yield return new object[] { "en-US", 1, "AD" }; - yield return new object[] { "en-VC", 0, "AD" }; - yield return new object[] { "en-VC", 1, "AD" }; - yield return new object[] { "en-VG", 0, "AD" }; - yield return new object[] { "en-VG", 1, "AD" }; - yield return new object[] { "en-VI", 0, "AD" }; - yield return new object[] { "en-VI", 1, "AD" }; - yield return new object[] { "en-VU", 0, "AD" }; - yield return new object[] { "en-VU", 1, "AD" }; - yield return new object[] { "en-WS", 0, "AD" }; - yield return new object[] { "en-WS", 1, "AD" }; - yield return new object[] { "en-ZA", 0, "AD" }; - yield return new object[] { "en-ZA", 1, "AD" }; - yield return new object[] { "en-ZM", 0, "AD" }; - yield return new object[] { "en-ZM", 1, "AD" }; - yield return new object[] { "en-ZW", 0, "AD" }; - yield return new object[] { "en-ZW", 1, "AD" }; - yield return new object[] { "en-US", 0, "AD" }; - yield return new object[] { "en-US", 1, "AD" }; - yield return new object[] { "es-ES", 0, "d. C." }; - yield return new object[] { "es-ES", 1, "d. C." }; - yield return new object[] { "es-419", 0, "d.C." }; - yield return new object[] { "es-419", 1, "d.C." }; - yield return new object[] { "es-MX", 0, "d.C." }; - yield return new object[] { "es-MX", 1, "d.C." }; - yield return new object[] { "et-EE", 0, "pKr" }; - yield return new object[] { "et-EE", 1, "pKr" }; - yield return new object[] { "fa-IR", 0, "ه.ش" }; // ه‍.ش. - yield return new object[] { "fa-IR", 1, "ه.ش" }; - yield return new object[] { "fi-FI", 0, "jKr." }; - yield return new object[] { "fi-FI", 1, "jKr." }; - yield return new object[] { "fil-PH", 0, "AD" }; - yield return new object[] { "fil-PH", 1, "AD" }; - yield return new object[] { "fr-BE", 0, "ap. J.-C." }; - yield return new object[] { "fr-BE", 1, "ap. J.-C." }; - yield return new object[] { "fr-CA", 0, "ap. J.-C." }; - yield return new object[] { "fr-CA", 1, "ap. J.-C." }; - yield return new object[] { "fr-CH", 0, "ap. J.-C." }; - yield return new object[] { "fr-CH", 1, "ap. J.-C." }; - yield return new object[] { "fr-FR", 0, "ap. J.-C." }; - yield return new object[] { "fr-FR", 1, "ap. J.-C." }; - yield return new object[] { "gu-IN", 0, "ઈ.સ." }; - yield return new object[] { "gu-IN", 1, "ઈ.સ." }; - yield return new object[] { "he-IL", 0, "לספירה" }; - yield return new object[] { "he-IL", 1, "לספירה" }; - yield return new object[] { "hi-IN", 0, "ईस्वी" }; - yield return new object[] { "hi-IN", 1, "ईस्वी" }; - yield return new object[] { "hr-BA", 0, "po. Kr." }; - yield return new object[] { "hr-BA", 1, "po. Kr." }; - yield return new object[] { "hr-HR", 0, "po. Kr." }; - yield return new object[] { "hr-HR", 1, "po. Kr." }; - yield return new object[] { "hu-HU", 0, "i. sz." }; - yield return new object[] { "hu-HU", 1, "i. sz." }; - yield return new object[] { "id-ID", 0, "M" }; - yield return new object[] { "id-ID", 1, "M" }; - yield return new object[] { "it-CH", 0, "d.C." }; - yield return new object[] { "it-CH", 1, "d.C." }; - yield return new object[] { "it-IT", 0, "d.C." }; - yield return new object[] { "it-IT", 1, "d.C." }; - yield return new object[] { "ja-JP", 0, "西暦" }; - yield return new object[] { "ja-JP", 1, "西暦" }; - yield return new object[] { "kn-IN", 0, "ಕ್ರಿ.ಶ" }; - yield return new object[] { "kn-IN", 1, "ಕ್ರಿ.ಶ" }; - yield return new object[] { "ko-KR", 0, "AD" }; - yield return new object[] { "ko-KR", 1, "AD" }; - yield return new object[] { "lt-LT", 0, "po Kr." }; - yield return new object[] { "lt-LT", 1, "po Kr." }; - yield return new object[] { "lv-LV", 0, "m.ē." }; - yield return new object[] { "lv-LV", 1, "m.ē." }; - yield return new object[] { "ml-IN", 0, "എഡി" }; - yield return new object[] { "ml-IN", 1, "എഡി" }; - yield return new object[] { "mr-IN", 0, "इ. स." }; - yield return new object[] { "mr-IN", 1, "इ. स." }; - yield return new object[] { "ms-BN", 0, "TM" }; - yield return new object[] { "ms-BN", 1, "TM" }; - yield return new object[] { "ms-MY", 0, "TM" }; - yield return new object[] { "ms-MY", 1, "TM" }; - yield return new object[] { "ms-SG", 0, "TM" }; - yield return new object[] { "ms-SG", 1, "TM" }; - yield return new object[] { "nb-NO", 0, "e.Kr." }; - yield return new object[] { "nb-NO", 1, "e.Kr." }; - yield return new object[] { "no", 0, "e.Kr." }; - yield return new object[] { "no", 1, "e.Kr." }; - yield return new object[] { "no-NO", 0, "e.Kr." }; - yield return new object[] { "no-NO", 1, "e.Kr." }; - yield return new object[] { "nl-AW", 0, "n.Chr." }; - yield return new object[] { "nl-AW", 1, "n.Chr." }; - yield return new object[] { "nl-BE", 0, "n.Chr." }; - yield return new object[] { "nl-BE", 1, "n.Chr." }; - yield return new object[] { "nl-NL", 0, "n.Chr." }; - yield return new object[] { "nl-NL", 1, "n.Chr." }; - yield return new object[] { "pl-PL", 0, "n.e." }; - yield return new object[] { "pl-PL", 1, "n.e." }; - yield return new object[] { "pt-BR", 0, "d.C." }; - yield return new object[] { "pt-BR", 1, "d.C." }; - yield return new object[] { "pt-PT", 0, "d.C." }; - yield return new object[] { "pt-PT", 1, "d.C." }; - yield return new object[] { "ro-RO", 0, "d.Hr." }; - yield return new object[] { "ro-RO", 1, "d.Hr." }; - yield return new object[] { "ru-RU", 0, "н. э." }; - yield return new object[] { "ru-RU", 1, "н. э." }; - yield return new object[] { "sk-SK", 0, "po Kr." }; - yield return new object[] { "sk-SK", 1, "po Kr." }; - yield return new object[] { "sl-SI", 0, "po Kr." }; - yield return new object[] { "sl-SI", 1, "po Kr." }; - yield return new object[] { "sr-Cyrl-RS", 0, "н. е." }; - yield return new object[] { "sr-Cyrl-RS", 1, "н. е." }; - yield return new object[] { "sr-Latn-RS", 0, "n. e." }; - yield return new object[] { "sr-Latn-RS", 1, "n. e." }; - yield return new object[] { "sv-AX", 0, "e.Kr." }; - yield return new object[] { "sv-AX", 1, "e.Kr." }; - yield return new object[] { "sv-SE", 0, "e.Kr." }; - yield return new object[] { "sv-SE", 1, "e.Kr." }; - yield return new object[] { "sw-CD", 0, "BK" }; - yield return new object[] { "sw-CD", 1, "BK" }; - yield return new object[] { "sw-KE", 0, "BK" }; - yield return new object[] { "sw-KE", 1, "BK" }; - yield return new object[] { "sw-TZ", 0, "BK" }; - yield return new object[] { "sw-TZ", 1, "BK" }; - yield return new object[] { "sw-UG", 0, "BK" }; - yield return new object[] { "sw-UG", 1, "BK" }; - yield return new object[] { "ta-IN", 0, "கி.பி." }; - yield return new object[] { "ta-IN", 1, "கி.பி." }; - yield return new object[] { "ta-LK", 0, "கி.பி." }; - yield return new object[] { "ta-LK", 1, "கி.பி." }; - yield return new object[] { "ta-MY", 0, "கி.பி." }; - yield return new object[] { "ta-MY", 1, "கி.பி." }; - yield return new object[] { "ta-SG", 0, "கி.பி." }; - yield return new object[] { "ta-SG", 1, "கி.பி." }; - yield return new object[] { "te-IN", 0, "క్రీశ" }; - yield return new object[] { "te-IN", 1, "క్రీశ" }; - yield return new object[] { "th-TH", 0, "พ.ศ." }; - yield return new object[] { "th-TH", 1, "พ.ศ." }; - yield return new object[] { "tr-CY", 0, "MS" }; - yield return new object[] { "tr-CY", 1, "MS" }; - yield return new object[] { "tr-TR", 0, "MS" }; - yield return new object[] { "tr-TR", 1, "MS" }; - yield return new object[] { "uk-UA", 0, "н. е." }; - yield return new object[] { "uk-UA", 1, "н. е." }; - yield return new object[] { "vi-VN", 0, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "CN" : "SCN" }; // sau CN - yield return new object[] { "vi-VN", 1, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "CN" : "SCN" }; // sau CN - yield return new object[] { "zh-CN", 0, "公元" }; - yield return new object[] { "zh-CN", 1, "公元" }; - yield return new object[] { "zh-Hans-HK", 0, "公元" }; - yield return new object[] { "zh-Hans-HK", 1, "公元" }; - yield return new object[] { "zh-SG", 0, "公元" }; - yield return new object[] { "zh-SG", 1, "公元" }; - yield return new object[] { "zh-HK", 0, "公元" }; - yield return new object[] { "zh-HK", 1, "公元" }; - yield return new object[] { "zh-TW", 0, "西元" }; - yield return new object[] { "zh-TW", 1, "西元" }; - } + yield return new object[] { "en-US", 1, DateTimeFormatInfoData.EnUSEraName() }; + yield return new object[] { "en-US", 0, DateTimeFormatInfoData.EnUSEraName() }; + yield return new object[] { "fr-FR", 1, "ap. J.-C." }; + yield return new object[] { "fr-FR", 0, "ap. J.-C." }; } [Theory] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongDatePattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongDatePattern.cs index 53720bf5bffbf..20be2cf3f2211 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongDatePattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongDatePattern.cs @@ -31,199 +31,6 @@ public static IEnumerable LongDatePattern_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, "dddd d MMMM yyyy" }; } - public static IEnumerable LongDatePattern_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] {"ar-SA", "dddd، d MMMM yyyy" }; // dddd، d MMMM yyyy g - yield return new object[] {"am-ET", "yyyy MMMM d, dddd" }; - yield return new object[] {"bg-BG", "dddd, d MMMM yyyy 'г'." }; - yield return new object[] {"bn-BD", "dddd, d MMMM, yyyy" }; - yield return new object[] {"bn-IN", "dddd, d MMMM, yyyy" }; - string catalanianPattern = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d 'de' MMMM 'de' yyyy" : "dddd, d 'de' MMMM 'del' yyyy"; // "dddd, d MMMM 'de' yyyy" - yield return new object[] {"ca-AD", catalanianPattern }; - yield return new object[] {"ca-ES", catalanianPattern }; - yield return new object[] {"cs-CZ", "dddd d. MMMM yyyy" }; - yield return new object[] {"da-DK", "dddd 'den' d. MMMM yyyy" }; - yield return new object[] {"de-AT", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-BE", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-CH", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-DE", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-IT", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-LI", "dddd, d. MMMM yyyy" }; - yield return new object[] {"de-LU", "dddd, d. MMMM yyyy" }; - yield return new object[] {"el-CY", "dddd d MMMM yyyy" }; // "dddd, d MMMM yyyy" - yield return new object[] {"el-GR", "dddd d MMMM yyyy" }; // "dddd, d MMMM yyyy" - yield return new object[] {"en-AE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-AG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-AI", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-AS", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-AT", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-AU", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM yyyy" : "dddd d MMMM yyyy" }; - yield return new object[] {"en-BB", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-BE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-BI", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-BM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-BS", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-BW", "dddd, d MMMM yyyy" }; // "dddd, dd MMMM yyyy" - yield return new object[] {"en-BZ", "dddd, d MMMM yyyy" }; // "dddd, dd MMMM yyyy" - yield return new object[] {"en-CA", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-CC", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-CH", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-CK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-CM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-CX", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-CY", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-DE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-DK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-DM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-ER", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-FI", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-FJ", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-FK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-FM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GB", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM yyyy" :"dddd d MMMM yyyy" }; - yield return new object[] {"en-GD", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GH", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GI", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-GU", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-GY", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-HK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-IE", "dddd d MMMM yyyy" }; - yield return new object[] {"en-IL", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-IM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-IN", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dddd, d MMMM, yyyy" : "dddd d MMMM, yyyy" }; // dddd, d MMMM, yyyy - yield return new object[] {"en-IO", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-JE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-JM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-KE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-KI", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-KN", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-KY", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-LC", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-LR", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-LS", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MH", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-MO", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MP", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-MS", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MT", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MU", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MW", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-MY", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NA", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NF", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NL", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NR", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NU", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-NZ", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-PG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-PH", "dddd, MMMM d, yyyy" }; // "dddd, d MMMM yyyy" - yield return new object[] {"en-PK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-PN", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-PR", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-PW", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-RW", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SB", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SC", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SD", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SE", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SH", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SI", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SL", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SS", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SX", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-SZ", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TC", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TK", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TO", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TT", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TV", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-TZ", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-UG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-UM", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-US", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-VC", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-VG", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-VI", "dddd, MMMM d, yyyy" }; - yield return new object[] {"en-VU", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-WS", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-ZA", "dddd, d MMMM yyyy" }; // "dddd, dd MMMM yyyy" - yield return new object[] {"en-ZM", "dddd, d MMMM yyyy" }; - yield return new object[] {"en-ZW", "dddd, d MMMM yyyy" }; // "dddd, dd MMMM yyyy" - yield return new object[] {"en-US", "dddd, MMMM d, yyyy" }; - string spanishPattern = "dddd, d 'de' MMMM 'de' yyyy"; - yield return new object[] {"es-419", spanishPattern }; - yield return new object[] {"es-ES", spanishPattern }; - yield return new object[] {"es-MX", spanishPattern }; - yield return new object[] {"et-EE", "dddd, d. MMMM yyyy" }; - yield return new object[] {"fa-IR", "yyyy MMMM d, dddd" }; - yield return new object[] {"fi-FI", "dddd d. MMMM yyyy" }; - yield return new object[] {"fil-PH", "dddd, MMMM d, yyyy" }; - yield return new object[] {"fr-BE", "dddd d MMMM yyyy" }; - yield return new object[] {"fr-CA", "dddd d MMMM yyyy" }; - yield return new object[] {"fr-CH", "dddd, d MMMM yyyy" }; - yield return new object[] {"fr-FR", "dddd d MMMM yyyy" }; - yield return new object[] {"gu-IN", "dddd, d MMMM, yyyy" }; - yield return new object[] {"he-IL", "dddd, d בMMMM yyyy" }; - yield return new object[] {"hi-IN", "dddd, d MMMM yyyy" }; - yield return new object[] {"hr-BA", "dddd, d. MMMM yyyy." }; - yield return new object[] {"hr-HR", "dddd, d. MMMM yyyy." }; - yield return new object[] {"hu-HU", "yyyy. MMMM d., dddd" }; - yield return new object[] {"id-ID", "dddd, d MMMM yyyy" }; // "dddd, dd MMMM yyyy" - yield return new object[] {"it-CH", "dddd, d MMMM yyyy" }; - yield return new object[] {"it-IT", "dddd d MMMM yyyy" }; - yield return new object[] {"ja-JP", "yyyy年M月d日dddd" }; - yield return new object[] {"kn-IN", "dddd, MMMM d, yyyy" }; - yield return new object[] {"ko-KR", "yyyy년 M월 d일 dddd" }; - yield return new object[] {"lt-LT", "yyyy 'm'. MMMM d 'd'., dddd" }; - yield return new object[] {"lv-LV", "dddd, yyyy. 'gada' d. MMMM" }; - yield return new object[] {"ml-IN", "yyyy, MMMM d, dddd" }; - yield return new object[] {"mr-IN", "dddd, d MMMM, yyyy" }; - yield return new object[] {"ms-BN", "dddd, d MMMM yyyy" }; // "dd MMMM yyyy" - yield return new object[] {"ms-MY", "dddd, d MMMM yyyy" }; - yield return new object[] {"ms-SG", "dddd, d MMMM yyyy" }; - yield return new object[] {"nb-NO", "dddd d. MMMM yyyy" }; - yield return new object[] {"no-NO", "dddd d. MMMM yyyy" }; - yield return new object[] {"nl-AW", "dddd d MMMM yyyy" }; - yield return new object[] {"nl-BE", "dddd d MMMM yyyy" }; - yield return new object[] {"nl-NL", "dddd d MMMM yyyy" }; - yield return new object[] {"pl-PL", "dddd, d MMMM yyyy" }; - yield return new object[] {"pt-BR", "dddd, d 'de' MMMM 'de' yyyy" }; - yield return new object[] {"pt-PT", "dddd, d 'de' MMMM 'de' yyyy" }; - yield return new object[] {"ro-RO", "dddd, d MMMM yyyy" }; - yield return new object[] {"ru-RU", "dddd, d MMMM yyyy 'г'." }; - yield return new object[] {"sk-SK", "dddd d. MMMM yyyy" }; - yield return new object[] {"sl-SI", "dddd, d. MMMM yyyy" }; // "dddd, dd. MMMM yyyy" - yield return new object[] {"sr-Cyrl-RS", "dddd, d. MMMM yyyy." }; // "dddd, dd. MMMM yyyy" - yield return new object[] {"sr-Latn-RS", "dddd, d. MMMM yyyy." }; // "dddd, dd. MMMM yyyy" - yield return new object[] {"sv-AX", "dddd d MMMM yyyy" }; - yield return new object[] {"sv-SE", "dddd d MMMM yyyy" }; - yield return new object[] {"sw-CD", "dddd, d MMMM yyyy" }; - yield return new object[] {"sw-KE", "dddd, d MMMM yyyy" }; - yield return new object[] {"sw-TZ", "dddd, d MMMM yyyy" }; - yield return new object[] {"sw-UG", "dddd, d MMMM yyyy" }; - yield return new object[] {"ta-IN", "dddd, d MMMM, yyyy" }; - yield return new object[] {"ta-LK", "dddd, d MMMM, yyyy" }; - yield return new object[] {"ta-MY", "dddd, d MMMM, yyyy" }; - yield return new object[] {"ta-SG", "dddd, d MMMM, yyyy" }; - yield return new object[] {"te-IN", "d, MMMM yyyy, dddd" }; - yield return new object[] {"th-TH", "ddddที่ d MMMM g yyyy" }; - yield return new object[] {"tr-CY", "d MMMM yyyy dddd" }; - yield return new object[] {"tr-TR", "d MMMM yyyy dddd" }; - yield return new object[] {"uk-UA", "dddd, d MMMM yyyy 'р'." }; - yield return new object[] {"vi-VN", "dddd, d MMMM, yyyy" }; - yield return new object[] {"zh-CN", "yyyy年M月d日dddd" }; - yield return new object[] {"zh-Hans-HK", "yyyy年M月d日dddd" }; - yield return new object[] {"zh-SG", "yyyy年M月d日dddd" }; - yield return new object[] {"zh-HK", "yyyy年M月d日dddd" }; - yield return new object[] {"zh-TW", "yyyy年M月d日 dddd" }; - } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(LongDatePattern_Get_TestData_ICU))] public void LongDatePattern_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string expected) @@ -231,14 +38,6 @@ public void LongDatePattern_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, s Assert.Equal(expected, format.LongDatePattern); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(LongDatePattern_Get_TestData_HybridGlobalization))] - public void LongDatePattern_Get_ReturnsExpected_HybridGlobalization(string cultureName, string expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - Assert.True(expected == format.LongDatePattern, $"Failed for culture: {cultureName}. Expected: {expected}, Actual: {format.LongDatePattern}"); - } - [Theory] [MemberData(nameof(LongDatePattern_Set_TestData))] public void LongDatePattern_Set_GetReturnsExpected(string value) diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongTimePattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongTimePattern.cs index dc02bcba5869d..455726b844d51 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongTimePattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoLongTimePattern.cs @@ -14,205 +14,6 @@ public void LongTimePattern_GetInvariantInfo_ReturnsExpected() Assert.Equal("HH:mm:ss", DateTimeFormatInfo.InvariantInfo.LongTimePattern); } - public static IEnumerable LongTimePattern_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "H:mm:ss ч." : "H:mm:ss" }; // H:mm:ss ч. - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, "HH.mm.ss" }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, "HH.mm.ss" }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, "H.mm.ss" }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, "HH:mm:ss" }; - string latinAmericaSpanishPattern = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "HH:mm:ss" : "h:mm:ss tt"; // H:mm:ss - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, latinAmericaSpanishPattern }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, latinAmericaSpanishPattern }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, "H.mm.ss" }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, "HH 'h' mm 'min' ss 's'" }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, "hh:mm:ss tt" }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, "HH.mm.ss" }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, "hh:mm:ss tt" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "tt h:mm:ss" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("no").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, "H:mm:ss" }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, "tt h:mm:ss" }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, "tt h:mm:ss" }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, "tt h:mm:ss" }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, "h:mm:ss tt" }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "HH:mm:ss" }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, "HH:mm:ss" }; // tth:mm:ss - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, "tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, "tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, "tth:mm:ss" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "tth:mm:ss" }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(LongTimePattern_Get_TestData_HybridGlobalization))] - public void LongTimePattern_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string value) - { - Assert.Equal(value, format.LongTimePattern); - } - public static IEnumerable LongTimePattern_Set_TestData() { yield return new object[] { string.Empty }; diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthDayPattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthDayPattern.cs index 4cce8b2086498..8708cc49417da 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthDayPattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthDayPattern.cs @@ -31,196 +31,6 @@ public static IEnumerable MonthDayPattern_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("en-US").DateTimeFormat, "MMMM d" }; yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, "d MMMM" }; } - - public static IEnumerable MonthDayPattern_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, "d de MMMM" }; // d MMMM - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, "d de MMMM" }; // d MMMM - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, "MMMM d" }; // "d MMMM" - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, "d de MMMM" }; // d 'de' MMMM - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "d de MMMM" }; // d 'de' MMMM - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, "d de MMMM" }; // d 'de' MMMM - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "d MMMM" }; // "MMMM d" - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, "d בMMMM" }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "MMMM d." }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "M月d日" }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "MMMM d일" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "MMMM d d." }; // MMMM d 'd'. - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "MMMM d" }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("no").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, "d de MMMM" }; // d 'de' MMMM - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "d de MMMM" }; // d 'de' MMMM - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "d. MMMM" }; - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "d MMMM" }; - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, "M月d日" }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, "M月d日" }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, "M月d日" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "M月d日" }; - } [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(MonthDayPattern_Get_TestData_ICU))] @@ -229,13 +39,6 @@ public void MonthDayPattern_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, s Assert.Equal(expected, format.MonthDayPattern); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(MonthDayPattern_Get_TestData_HybridGlobalization))] - public void MonthDayPattern_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string expected) - { - Assert.Equal(expected, format.MonthDayPattern); - } - [Theory] [MemberData(nameof(MonthDayPattern_Set_TestData))] public void MonthDayPattern_Set_GetReturnsExpected(string value) diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthGenitiveNames.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthGenitiveNames.cs index 5167679d8cb2b..68fcfd6e08a62 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthGenitiveNames.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthGenitiveNames.cs @@ -36,204 +36,6 @@ public static IEnumerable MonthGenitiveNames_Get_TestData() yield return new object[] { CultureInfo.GetCultureInfo("en-US").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; } - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, new string[] { "محرم", "صفر", "ربيع الأول", "ربيع الآخر", "جمادى الأولى", "جمادى الآخرة", "رجب", "شعبان", "رمضان", "شوال", "ذو القعدة", "ذو الحجة", "" } }; - if (PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS) - { - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, new string[] { "ጃንዩወሪ", "ፌብሩወሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" } }; - } - else - { - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, new string[] { "ጃንዋሪ", "ፌብሩዋሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" } }; // "ጃንዩወሪ", "ፌብሩወሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" - } - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, new string[] { "януари", "февруари", "март", "април", "май", "юни", "юли", "август", "септември", "октомври", "ноември", "декември", "" } }; - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, new string[] { "জানুয়ারী", "ফেব্রুয়ারী", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" } }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, new string[] { "জানুয়ারী", "ফেব্রুয়ারী", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" } }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, new string[] { "gener", "febrer", "març", "abril", "maig", "juny", "juliol", "agost", "setembre", "octubre", "novembre", "desembre", "" } }; // "de gener", "de febrer", "de març", "d’abril", "de maig", "de juny", "de juliol", "d’agost", "de setembre", "d’octubre", "de novembre", "de desembre", "" - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, new string[] { "gener", "febrer", "març", "abril", "maig", "juny", "juliol", "agost", "setembre", "octubre", "novembre", "desembre", "" } }; // "de gener", "de febrer", "de març", "d’abril", "de maig", "de juny", "de juliol", "d’agost", "de setembre", "d’octubre", "de novembre", "de desembre", "" - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, new string[] { "ledna", "února", "března", "dubna", "května", "června", "července", "srpna", "září", "října", "listopadu", "prosince", "" } }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, new string[] { "januar", "februar", "marts", "april", "maj", "juni", "juli", "august", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, new string[] { "Jänner", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, new string[] { "Jänner", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, new string[] { "Ιανουαρίου", "Φεβρουαρίου", "Μαρτίου", "Απριλίου", "Μαΐου", "Ιουνίου", "Ιουλίου", "Αυγούστου", "Σεπτεμβρίου", "Οκτωβρίου", "Νοεμβρίου", "Δεκεμβρίου", "" } }; - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, new string[] { "Ιανουαρίου", "Φεβρουαρίου", "Μαρτίου", "Απριλίου", "Μαΐου", "Ιουνίου", "Ιουλίου", "Αυγούστου", "Σεπτεμβρίου", "Οκτωβρίου", "Νοεμβρίου", "Δεκεμβρίου", "" } }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, new string[] { "jaanuar", "veebruar", "märts", "aprill", "mai", "juuni", "juuli", "august", "september", "oktoober", "november", "detsember", "" } }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, new string[] { "فروردین", "اردیبهشت", "خرداد", "تیر", "مرداد", "شهریور", "مهر", "آبان", "آذر", "دی", "بهمن", "اسفند", "" } }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, new string[] { "tammikuuta", "helmikuuta", "maaliskuuta", "huhtikuuta", "toukokuuta", "kesäkuuta", "heinäkuuta", "elokuuta", "syyskuuta", "lokakuuta", "marraskuuta", "joulukuuta", "" } }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, new string[] { "Enero", "Pebrero", "Marso", "Abril", "Mayo", "Hunyo", "Hulyo", "Agosto", "Setyembre", "Oktubre", "Nobyembre", "Disyembre", "" } }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, new string[] { "જાન્યુઆરી", "ફેબ્રુઆરી", "માર્ચ", "એપ્રિલ", "મે", "જૂન", "જુલાઈ", "ઑગસ્ટ", "સપ્ટેમ્બર", "ઑક્ટોબર", "નવેમ્બર", "ડિસેમ્બર", "" } }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, new string[] { "ינואר", "פברואר", "מרץ", "אפריל", "מאי", "יוני", "יולי", "אוגוסט", "ספטמבר", "אוקטובר", "נובמבר", "דצמבר", "" } }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, new string[] { "जनवरी", "फ़रवरी", "मार्च", "अप्रैल", "मई", "जून", "जुलाई", "अगस्त", "सितंबर", "अक्तूबर", "नवंबर", "दिसंबर", "" } }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, new string[] { "siječnja", "veljače", "ožujka", "travnja", "svibnja", "lipnja", "srpnja", "kolovoza", "rujna", "listopada", "studenoga", "prosinca", "" } }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, new string[] { "siječnja", "veljače", "ožujka", "travnja", "svibnja", "lipnja", "srpnja", "kolovoza", "rujna", "listopada", "studenoga", "prosinca", "" } }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, new string[] { "január", "február", "március", "április", "május", "június", "július", "augusztus", "szeptember", "október", "november", "december", "" } }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, new string[] { "Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September", "Oktober", "November", "Desember", "" } }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, new string[] { "gennaio", "febbraio", "marzo", "aprile", "maggio", "giugno", "luglio", "agosto", "settembre", "ottobre", "novembre", "dicembre", "" } }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, new string[] { "gennaio", "febbraio", "marzo", "aprile", "maggio", "giugno", "luglio", "agosto", "settembre", "ottobre", "novembre", "dicembre", "" } }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, new string[] { "ಜನವರಿ", "ಫೆಬ್ರವರಿ", "ಮಾರ್ಚ್", "ಏಪ್ರಿಲ್", "ಮೇ", "ಜೂನ್", "ಜುಲೈ", "ಆಗಸ್ಟ್", "ಸೆಪ್ಟೆಂಬರ್", "ಅಕ್ಟೋಬರ್", "ನವೆಂಬರ್", "ಡಿಸೆಂಬರ್", "" } }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, new string[] { "1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월", "" } }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, new string[] { "sausio", "vasario", "kovo", "balandžio", "gegužės", "birželio", "liepos", "rugpjūčio", "rugsėjo", "spalio", "lapkričio", "gruodžio", "" } }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, new string[] { "janvāris", "februāris", "marts", "aprīlis", "maijs", "jūnijs", "jūlijs", "augusts", "septembris", "oktobris", "novembris", "decembris", "" } }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, new string[] { "ജനുവരി", "ഫെബ്രുവരി", "മാർച്ച്", "ഏപ്രിൽ", "മേയ്", "ജൂൺ", "ജൂലൈ", "ഓഗസ്റ്റ്", "സെപ്റ്റംബർ", "ഒക്‌ടോബർ", "നവംബർ", "ഡിസംബർ", "" } }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, new string[] { "जानेवारी", "फेब्रुवारी", "मार्च", "एप्रिल", "मे", "जून", "जुलै", "ऑगस्ट", "सप्टेंबर", "ऑक्टोबर", "नोव्हेंबर", "डिसेंबर", "" } }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("no").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, new string[] { "stycznia", "lutego", "marca", "kwietnia", "maja", "czerwca", "lipca", "sierpnia", "września", "października", "listopada", "grudnia", "" } }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, new string[] { "janeiro", "fevereiro", "março", "abril", "maio", "junho", "julho", "agosto", "setembro", "outubro", "novembro", "dezembro", "" } }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, new string[] { "janeiro", "fevereiro", "março", "abril", "maio", "junho", "julho", "agosto", "setembro", "outubro", "novembro", "dezembro", "" } }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, new string[] { "ianuarie", "februarie", "martie", "aprilie", "mai", "iunie", "iulie", "august", "septembrie", "octombrie", "noiembrie", "decembrie", "" } }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, new string[] { "января", "февраля", "марта", "апреля", "мая", "июня", "июля", "августа", "сентября", "октября", "ноября", "декабря", "" } }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, new string[] { "januára", "februára", "marca", "apríla", "mája", "júna", "júla", "augusta", "septembra", "októbra", "novembra", "decembra", "" } }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, new string[] { "januar", "februar", "marec", "april", "maj", "junij", "julij", "avgust", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, new string[] { "јануар", "фебруар", "март", "април", "мај", "јун", "јул", "август", "септембар", "октобар", "новембар", "децембар", "" } }; - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, new string[] { "januar", "februar", "mart", "april", "maj", "jun", "jul", "avgust", "septembar", "oktobar", "novembar", "decembar", "" } }; - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, new string[] { "januari", "februari", "mars", "april", "maj", "juni", "juli", "augusti", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, new string[] { "januari", "februari", "mars", "april", "maj", "juni", "juli", "augusti", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, new string[] { "జనవరి", "ఫిబ్రవరి", "మార్చి", "ఏప్రిల్", "మే", "జూన్", "జులై", "ఆగస్టు", "సెప్టెంబర్", "అక్టోబర్", "నవంబర్", "డిసెంబర్", "" } }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, new string[] { "มกราคม", "กุมภาพันธ์", "มีนาคม", "เมษายน", "พฤษภาคม", "มิถุนายน", "กรกฎาคม", "สิงหาคม", "กันยายน", "ตุลาคม", "พฤศจิกายน", "ธันวาคม", "" } }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, new string[] { "Ocak", "Şubat", "Mart", "Nisan", "Mayıs", "Haziran", "Temmuz", "Ağustos", "Eylül", "Ekim", "Kasım", "Aralık", "" } }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, new string[] { "Ocak", "Şubat", "Mart", "Nisan", "Mayıs", "Haziran", "Temmuz", "Ağustos", "Eylül", "Ekim", "Kasım", "Aralık", "" } }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, new string[] { "січня", "лютого", "березня", "квітня", "травня", "червня", "липня", "серпня", "вересня", "жовтня", "листопада", "грудня", "" } }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, new string[] { "Tháng 1", "Tháng 2", "Tháng 3", "Tháng 4", "Tháng 5", "Tháng 6", "Tháng 7", "Tháng 8", "Tháng 9", "Tháng 10", "Tháng 11", "Tháng 12", "" } }; // ICU: tháng - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, new string[] { "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" } }; - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, new string[] { "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" } }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; // "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - } } [Theory] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthNames.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthNames.cs index e4d1b6084dd1c..aa4c05574b54b 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthNames.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoMonthNames.cs @@ -34,205 +34,6 @@ public static IEnumerable MonthNames_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; } - public static IEnumerable MonthNames_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, new string[] { "محرم", "صفر", "ربيع الأول", "ربيع الآخر", "جمادى الأولى", "جمادى الآخرة", "رجب", "شعبان", "رمضان", "شوال", "ذو القعدة", "ذو الحجة", "" } }; - if (PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS) - { - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, new string[] { "ጃንዩወሪ", "ፌብሩወሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" } }; - } - else - { - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, new string[] { "ጃንዋሪ", "ፌብሩዋሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" } }; // "ጃንዩወሪ", "ፌብሩወሪ", "ማርች", "ኤፕሪል", "ሜይ", "ጁን", "ጁላይ", "ኦገስት", "ሴፕቴምበር", "ኦክቶበር", "ኖቬምበር", "ዲሴምበር", "" - } - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, new string[] { "януари", "февруари", "март", "април", "май", "юни", "юли", "август", "септември", "октомври", "ноември", "декември", "" } }; - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, new string[] { "জানুয়ারী", "ফেব্রুয়ারী", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" } }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, new string[] { "জানুয়ারী", "ফেব্রুয়ারী", "মার্চ", "এপ্রিল", "মে", "জুন", "জুলাই", "আগস্ট", "সেপ্টেম্বর", "অক্টোবর", "নভেম্বর", "ডিসেম্বর", "" } }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, new string[] { "gener", "febrer", "març", "abril", "maig", "juny", "juliol", "agost", "setembre", "octubre", "novembre", "desembre", "" } }; - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, new string[] { "gener", "febrer", "març", "abril", "maig", "juny", "juliol", "agost", "setembre", "octubre", "novembre", "desembre", "" } }; - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, new string[] { "leden", "únor", "březen", "duben", "květen", "červen", "červenec", "srpen", "září", "říjen", "listopad", "prosinec", "" } }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, new string[] { "januar", "februar", "marts", "april", "maj", "juni", "juli", "august", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, new string[] { "Jänner", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, new string[] { "Jänner", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, new string[] { "Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember", "" } }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, new string[] { "Ιανουαρίου", "Φεβρουαρίου", "Μαρτίου", "Απριλίου", "Μαΐου", "Ιουνίου", "Ιουλίου", "Αυγούστου", "Σεπτεμβρίου", "Οκτωβρίου", "Νοεμβρίου", "Δεκεμβρίου", "" } }; // BUG!!! JS returns Genitive for Greek even though we expect Nominative; "Ιανουάριος", "Φεβρουάριος", "Μάρτιος", "Απρίλιος", "Μάιος", "Ιούνιος", "Ιούλιος", "Αύγουστος", "Σεπτέμβριος", "Οκτώβριος", "Νοέμβριος", "Δεκέμβριος" - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, new string[] { "Ιανουαρίου", "Φεβρουαρίου", "Μαρτίου", "Απριλίου", "Μαΐου", "Ιουνίου", "Ιουλίου", "Αυγούστου", "Σεπτεμβρίου", "Οκτωβρίου", "Νοεμβρίου", "Δεκεμβρίου", "" } }; // BUG!!! JS returns Genitive for Greek even though we expect Nominative; "Ιανουάριος", "Φεβρουάριος", "Μάρτιος", "Απρίλιος", "Μάιος", "Ιούνιος", "Ιούλιος", "Αύγουστος", "Σεπτέμβριος", "Οκτώβριος", "Νοέμβριος", "Δεκέμβριος" - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, new string[] { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", "" } }; - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, new string[] { "enero", "febrero", "marzo", "abril", "mayo", "junio", "julio", "agosto", "septiembre", "octubre", "noviembre", "diciembre", "" } }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, new string[] { "jaanuar", "veebruar", "märts", "aprill", "mai", "juuni", "juuli", "august", "september", "oktoober", "november", "detsember", "" } }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, new string[] { "فروردین", "اردیبهشت", "خرداد", "تیر", "مرداد", "شهریور", "مهر", "آبان", "آذر", "دی", "بهمن", "اسفند", "" } }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, new string[] { "tammikuu", "helmikuu", "maaliskuu", "huhtikuu", "toukokuu", "kesäkuu", "heinäkuu", "elokuu", "syyskuu", "lokakuu", "marraskuu", "joulukuu", "" } }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, new string[] { "Enero", "Pebrero", "Marso", "Abril", "Mayo", "Hunyo", "Hulyo", "Agosto", "Setyembre", "Oktubre", "Nobyembre", "Disyembre", "" } }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, new string[] { "janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre", "" } }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, new string[] { "જાન્યુઆરી", "ફેબ્રુઆરી", "માર્ચ", "એપ્રિલ", "મે", "જૂન", "જુલાઈ", "ઑગસ્ટ", "સપ્ટેમ્બર", "ઑક્ટોબર", "નવેમ્બર", "ડિસેમ્બર", "" } }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, new string[] { "ינואר", "פברואר", "מרץ", "אפריל", "מאי", "יוני", "יולי", "אוגוסט", "ספטמבר", "אוקטובר", "נובמבר", "דצמבר", "" } }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, new string[] { "जनवरी", "फ़रवरी", "मार्च", "अप्रैल", "मई", "जून", "जुलाई", "अगस्त", "सितंबर", "अक्तूबर", "नवंबर", "दिसंबर", "" } }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, new string[] { "siječanj", "veljača", "ožujak", "travanj", "svibanj", "lipanj", "srpanj", "kolovoz", "rujan", "listopad", "studeni", "prosinac", "" } }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, new string[] { "siječanj", "veljača", "ožujak", "travanj", "svibanj", "lipanj", "srpanj", "kolovoz", "rujan", "listopad", "studeni", "prosinac", "" } }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, new string[] { "január", "február", "március", "április", "május", "június", "július", "augusztus", "szeptember", "október", "november", "december", "" } }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, new string[] { "Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September", "Oktober", "November", "Desember", "" } }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, new string[] { "gennaio", "febbraio", "marzo", "aprile", "maggio", "giugno", "luglio", "agosto", "settembre", "ottobre", "novembre", "dicembre", "" } }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, new string[] { "gennaio", "febbraio", "marzo", "aprile", "maggio", "giugno", "luglio", "agosto", "settembre", "ottobre", "novembre", "dicembre", "" } }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, new string[] { "ಜನವರಿ", "ಫೆಬ್ರವರಿ", "ಮಾರ್ಚ್", "ಏಪ್ರಿಲ್", "ಮೇ", "ಜೂನ್", "ಜುಲೈ", "ಆಗಸ್ಟ್", "ಸೆಪ್ಟೆಂಬರ್", "ಅಕ್ಟೋಬರ್", "ನವೆಂಬರ್", "ಡಿಸೆಂಬರ್", "" } }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, new string[] { "1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월", "" } }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, new string[] { "sausis", "vasaris", "kovas", "balandis", "gegužė", "birželis", "liepa", "rugpjūtis", "rugsėjis", "spalis", "lapkritis", "gruodis", "" } }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, new string[] { "janvāris", "februāris", "marts", "aprīlis", "maijs", "jūnijs", "jūlijs", "augusts", "septembris", "oktobris", "novembris", "decembris", "" } }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, new string[] { "ജനുവരി", "ഫെബ്രുവരി", "മാർച്ച്", "ഏപ്രിൽ", "മേയ്", "ജൂൺ", "ജൂലൈ", "ഓഗസ്റ്റ്", "സെപ്റ്റംബർ", "ഒക്‌ടോബർ", "നവംബർ", "ഡിസംബർ", "" } }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, new string[] { "जानेवारी", "फेब्रुवारी", "मार्च", "एप्रिल", "मे", "जून", "जुलै", "ऑगस्ट", "सप्टेंबर", "ऑक्टोबर", "नोव्हेंबर", "डिसेंबर", "" } }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, new string[] { "Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember", "" } }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("no").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, new string[] { "januar", "februar", "mars", "april", "mai", "juni", "juli", "august", "september", "oktober", "november", "desember", "" } }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, new string[] { "januari", "februari", "maart", "april", "mei", "juni", "juli", "augustus", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, new string[] { "styczeń", "luty", "marzec", "kwiecień", "maj", "czerwiec", "lipiec", "sierpień", "wrzesień", "październik", "listopad", "grudzień", "" } }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, new string[] { "janeiro", "fevereiro", "março", "abril", "maio", "junho", "julho", "agosto", "setembro", "outubro", "novembro", "dezembro", "" } }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, new string[] { "janeiro", "fevereiro", "março", "abril", "maio", "junho", "julho", "agosto", "setembro", "outubro", "novembro", "dezembro", "" } }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, new string[] { "ianuarie", "februarie", "martie", "aprilie", "mai", "iunie", "iulie", "august", "septembrie", "octombrie", "noiembrie", "decembrie", "" } }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, new string[] { "январь", "февраль", "март", "апрель", "май", "июнь", "июль", "август", "сентябрь", "октябрь", "ноябрь", "декабрь", "" } }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, new string[] { "január", "február", "marec", "apríl", "máj", "jún", "júl", "august", "september", "október", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, new string[] { "januar", "februar", "marec", "april", "maj", "junij", "julij", "avgust", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, new string[] { "јануар", "фебруар", "март", "април", "мај", "јун", "јул", "август", "септембар", "октобар", "новембар", "децембар", "" } }; - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, new string[] { "januar", "februar", "mart", "april", "maj", "jun", "jul", "avgust", "septembar", "oktobar", "novembar", "decembar", "" } }; - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, new string[] { "januari", "februari", "mars", "april", "maj", "juni", "juli", "augusti", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, new string[] { "januari", "februari", "mars", "april", "maj", "juni", "juli", "augusti", "september", "oktober", "november", "december", "" } }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, new string[] { "Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba", "" } }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, new string[] { "ஜனவரி", "பிப்ரவரி", "மார்ச்", "ஏப்ரல்", "மே", "ஜூன்", "ஜூலை", "ஆகஸ்ட்", "செப்டம்பர்", "அக்டோபர்", "நவம்பர்", "டிசம்பர்", "" } }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, new string[] { "జనవరి", "ఫిబ్రవరి", "మార్చి", "ఏప్రిల్", "మే", "జూన్", "జులై", "ఆగస్టు", "సెప్టెంబర్", "అక్టోబర్", "నవంబర్", "డిసెంబర్", "" } }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, new string[] { "มกราคม", "กุมภาพันธ์", "มีนาคม", "เมษายน", "พฤษภาคม", "มิถุนายน", "กรกฎาคม", "สิงหาคม", "กันยายน", "ตุลาคม", "พฤศจิกายน", "ธันวาคม", "" } }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, new string[] { "Ocak", "Şubat", "Mart", "Nisan", "Mayıs", "Haziran", "Temmuz", "Ağustos", "Eylül", "Ekim", "Kasım", "Aralık", "" } }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, new string[] { "Ocak", "Şubat", "Mart", "Nisan", "Mayıs", "Haziran", "Temmuz", "Ağustos", "Eylül", "Ekim", "Kasım", "Aralık", "" } }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, new string[] { "січень", "лютий", "березень", "квітень", "травень", "червень", "липень", "серпень", "вересень", "жовтень", "листопад", "грудень", "" } }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, new string[] { "Tháng 1", "Tháng 2", "Tháng 3", "Tháng 4", "Tháng 5", "Tháng 6", "Tháng 7", "Tháng 8", "Tháng 9", "Tháng 10", "Tháng 11", "Tháng 12", "" } }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, new string[] { "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" } }; - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, new string[] { "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" } }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; // "一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月", "" - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, new string[] { "1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月", "" } }; - } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(MonthNames_Get_TestData_ICU))] public void MonthNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string[] expected) @@ -240,13 +41,6 @@ public void MonthNames_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string Assert.Equal(expected, format.MonthNames); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(MonthNames_Get_TestData_HybridGlobalization))] - public void MonthNames_Get_ReturnsExpected(DateTimeFormatInfo format, string[] expected) - { - Assert.Equal(expected, format.MonthNames); - } - [Theory] [MemberData(nameof(MonthNames_Set_TestData))] public void MonthNames_Set_GetReturnsExpected(string[] value) diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoNativeCalendarName.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoNativeCalendarName.cs deleted file mode 100644 index 377e6d30d597b..0000000000000 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoNativeCalendarName.cs +++ /dev/null @@ -1,214 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using Xunit; -using System.Collections.Generic; - -namespace System.Globalization.Tests -{ - public class DateTimeFormatInfoNativeCalendarName - { - public static IEnumerable NativeCalendarName_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, in this collection it always differs - string islamicName = PlatformDetection.IsFirefox ? "UMALQURA" : "islamic-umalqura"; - string gregorianName = PlatformDetection.IsFirefox ? "GREGORIAN" : "gregory"; - string persianName = PlatformDetection.IsFirefox ? "PERSIAN" : "persian"; - string bhuddistName = PlatformDetection.IsFirefox ? "THAI" : "buddhist"; - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, islamicName }; // التقويم الإسلامي (أم القرى) - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, gregorianName }; // የግሪጎሪያን የቀን አቆጣጠር - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, gregorianName }; // григориански календар - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, gregorianName }; // গ্রিগোরিয়ান ক্যালেন্ডার - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, gregorianName }; // গ্রিগোরিয়ান ক্যালেন্ডার - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, gregorianName }; // calendari gregorià - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, gregorianName }; // calendari gregorià - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, gregorianName }; // Gregoriánský kalendář - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, gregorianName }; // gregoriansk kalender - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, gregorianName }; // Gregorianischer Kalender - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, gregorianName }; // Γρηγοριανό ημερολόγιο - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, gregorianName }; // Gregorian Calendar - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, gregorianName }; // calendario gregoriano - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, gregorianName }; // Gregoriuse kalender - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, persianName }; // تقویم هجری شمسی - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, gregorianName }; // gregoriaaninen kalenteri - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, gregorianName }; // Gregorian na Kalendaryo - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, gregorianName }; // calendrier grégorien - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, gregorianName }; // ગ્રેગોરિઅન કેલેન્ડર - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, gregorianName }; // לוח השנה הגרגוריאני - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, gregorianName }; // ग्रेगोरियन कैलेंडर" - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, gregorianName }; // gregorijanski kalendar - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, gregorianName }; // Gergely-naptár - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, gregorianName }; // Kalender Gregorian" - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, gregorianName }; // Calendario gregoriano - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, gregorianName }; // 西暦(グレゴリオ暦) - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, gregorianName }; // ಗ್ರೆಗೋರಿಯನ್ ಕ್ಯಾಲೆಂಡರ್ - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, gregorianName }; // 양력 - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, gregorianName }; // Grigaliaus kalendorius - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, gregorianName }; // Gregora kalendārs - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, gregorianName }; // ഇംഗ്ലീഷ് കലണ്ടർ - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, gregorianName }; // ग्रेगोरियन दिनदर्शिका - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, gregorianName }; // Kalendar Gregory - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, gregorianName }; // gregoriansk kalender - yield return new object[] { new CultureInfo("no").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, gregorianName }; // Gregoriaanse kalender - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, gregorianName }; // kalendarz gregoriański - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, gregorianName }; // Calendário Gregoriano - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, gregorianName }; // calendar gregory - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, gregorianName }; // григорианский календарь - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, gregorianName }; // gregoriánsky kalendár - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, gregorianName }; // gregorijanski koledar - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, gregorianName }; // грегоријански календар - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, gregorianName }; // gregorijanski kalendar - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, gregorianName }; // gregoriansk kalender - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, gregorianName }; // Kalenda ya Kigregori - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, gregorianName }; // கிரிகோரியன் நாள்காட்டி - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, gregorianName };// గ్రేగోరియన్ క్యాలెండర్ - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, bhuddistName }; // ปฏิทินพุทธ - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, gregorianName }; // Miladi Takvim - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, gregorianName }; // григоріанський календар - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, gregorianName }; // Lịch Gregory - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, gregorianName }; // 公历 - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, gregorianName }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, gregorianName }; // 公曆 - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, gregorianName }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(NativeCalendarName_Get_TestData_HybridGlobalization))] - public void NativeCalendarName_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string expected) - { - Assert.Equal(expected, format.NativeCalendarName); - } - } -} diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoPMDesignator.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoPMDesignator.cs index c85029aabfc4e..cf0504082c543 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoPMDesignator.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoPMDesignator.cs @@ -14,206 +14,6 @@ public void PMDesignator_GetInvariantInfo_ReturnsExpected() Assert.Equal("PM", DateTimeFormatInfo.InvariantInfo.PMDesignator); } - public static IEnumerable PMDesignator_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "م" }; - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, "ከሰዓት" }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, "сл.об." }; - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, "p.\u00A0m." }; - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, "p.\u00A0m." }; - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, "odp." }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, "μ.μ." }; - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, "μ.μ." }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, "PM" }; // "pm" - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, "pm" }; - string latinAmericaSpanishDesignator = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "p.\u00A0m." : "p.m."; // p.m. - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, latinAmericaSpanishDesignator }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "p.\u00A0m." }; // p.m. - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, latinAmericaSpanishDesignator }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "بعدازظهر" }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, "ip." }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, "אחה״צ" }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, "pm" }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "du." }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "午後" }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, "ಅಪರಾಹ್ನ" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "오후" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "popiet" }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "pēcpusdienā" }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, "PM" }; // म.उ. - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, "PTG" }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, "PTG" }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, "PTG" }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("no").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "da tarde" }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, "p.m." }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, "pop." }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, "PM" }; // по подне - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "PM" }; // po podne - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, "em" }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, "em" }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, "PM" }; - string tamilDesignator = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "பிற்பகல்" : "PM"; // பிற்பகல் - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, tamilDesignator }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, tamilDesignator }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, tamilDesignator }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, tamilDesignator }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, "PM" }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, "หลังเที่ยง" }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, "ÖS" }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, "ÖS" }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, "пп" }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "CH" }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, "下午" }; - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, "下午" }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, "下午" }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, "下午" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "下午" }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(PMDesignator_Get_TestData_HybridGlobalization))] - public void PMDesignator_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string value) - { - Assert.Equal(value, format.PMDesignator); - } - [Theory] [InlineData("")] [InlineData("PP")] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortDatePattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortDatePattern.cs index 8922b19610e43..a15f119648131 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortDatePattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortDatePattern.cs @@ -14,197 +14,6 @@ public static IEnumerable ShortDatePattern_Get_TestData_ICU() yield return new object[] { CultureInfo.GetCultureInfo("fr-FR").DateTimeFormat, "dd/MM/yyyy" }; } - public static IEnumerable ShortDatePattern_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { "ar-SA", "d\u200f/M\u200f/yyyy" }; // "d\u200f/M\u200f/yyyy g" - yield return new object[] { "am-ET", "dd/MM/yyyy" }; - yield return new object[] { "bg-BG", "d.MM.yyyy г." }; // "d.MM.yyyy 'г'." - yield return new object[] { "bn-BD", "d/M/yyyy" }; - yield return new object[] { "bn-IN", "d/M/yyyy" }; - yield return new object[] { "ca-AD", "d/M/yyyy" }; - yield return new object[] { "ca-ES", "d/M/yyyy" }; - yield return new object[] { "cs-CZ", "dd.MM.yyyy" }; - yield return new object[] { "da-DK", "dd.MM.yyyy" }; - yield return new object[] { "de-AT", "dd.MM.yyyy" }; - yield return new object[] { "de-BE", "dd.MM.yyyy" }; - yield return new object[] { "de-CH", "dd.MM.yyyy" }; - yield return new object[] { "de-DE", "dd.MM.yyyy" }; - yield return new object[] { "de-IT", "dd.MM.yyyy" }; - yield return new object[] { "de-LI", "dd.MM.yyyy" }; - yield return new object[] { "de-LU", "dd.MM.yyyy" }; - yield return new object[] { "el-CY", "d/M/yyyy" }; - yield return new object[] { "el-GR", "d/M/yyyy" }; - yield return new object[] { "en-AE", "dd/MM/yyyy" }; - yield return new object[] { "en-AG", "dd/MM/yyyy" }; - yield return new object[] { "en-AI", "dd/MM/yyyy" }; - yield return new object[] { "en-AS", "M/d/yyyy" }; - yield return new object[] { "en-AT", "dd/MM/yyyy" }; - yield return new object[] { "en-AU", "d/M/yyyy" }; - yield return new object[] { "en-BB", "dd/MM/yyyy" }; - yield return new object[] { "en-BE", "dd/MM/yyyy" }; - yield return new object[] { "en-BI", "M/d/yyyy" }; - yield return new object[] { "en-BM", "dd/MM/yyyy" }; - yield return new object[] { "en-BS", "dd/MM/yyyy" }; - yield return new object[] { "en-BW", "dd/MM/yyyy" }; - yield return new object[] { "en-BZ", "dd/MM/yyyy" }; - yield return new object[] { "en-CA", "yyyy-MM-dd" }; - yield return new object[] { "en-CC", "dd/MM/yyyy" }; - yield return new object[] { "en-CH", "dd.MM.yyyy" }; // "dd/MM/yyyy" - yield return new object[] { "en-CK", "dd/MM/yyyy" }; - yield return new object[] { "en-CM", "dd/MM/yyyy" }; - yield return new object[] { "en-CX", "dd/MM/yyyy" }; - yield return new object[] { "en-CY", "dd/MM/yyyy" }; - yield return new object[] { "en-DE", "dd/MM/yyyy" }; - yield return new object[] { "en-DK", "dd/MM/yyyy" }; - yield return new object[] { "en-DM", "dd/MM/yyyy" }; - yield return new object[] { "en-ER", "dd/MM/yyyy" }; - yield return new object[] { "en-FI", "dd/MM/yyyy" }; - yield return new object[] { "en-FJ", "dd/MM/yyyy" }; - yield return new object[] { "en-FK", "dd/MM/yyyy" }; - yield return new object[] { "en-FM", "dd/MM/yyyy" }; - yield return new object[] { "en-GB", "dd/MM/yyyy" }; - yield return new object[] { "en-GD", "dd/MM/yyyy" }; - yield return new object[] { "en-GG", "dd/MM/yyyy" }; - yield return new object[] { "en-GH", "dd/MM/yyyy" }; - yield return new object[] { "en-GI", "dd/MM/yyyy" }; - yield return new object[] { "en-GM", "dd/MM/yyyy" }; - yield return new object[] { "en-GU", "M/d/yyyy" }; - yield return new object[] { "en-GY", "dd/MM/yyyy" }; - yield return new object[] { "en-HK", "d/M/yyyy" }; - yield return new object[] { "en-IE", "dd/MM/yyyy" }; - yield return new object[] { "en-IL", "dd/MM/yyyy" }; - yield return new object[] { "en-IM", "dd/MM/yyyy" }; - yield return new object[] { "en-IN", "dd/MM/yyyy" }; - yield return new object[] { "en-IO", "dd/MM/yyyy" }; - yield return new object[] { "en-JE", "dd/MM/yyyy" }; - yield return new object[] { "en-JM", "dd/MM/yyyy" }; - yield return new object[] { "en-KE", "dd/MM/yyyy" }; - yield return new object[] { "en-KI", "dd/MM/yyyy" }; - yield return new object[] { "en-KN", "dd/MM/yyyy" }; - yield return new object[] { "en-KY", "dd/MM/yyyy" }; - yield return new object[] { "en-LC", "dd/MM/yyyy" }; - yield return new object[] { "en-LR", "dd/MM/yyyy" }; - yield return new object[] { "en-LS", "dd/MM/yyyy" }; - yield return new object[] { "en-MG", "dd/MM/yyyy" }; - yield return new object[] { "en-MH", "M/d/yyyy" }; - yield return new object[] { "en-MO", "dd/MM/yyyy" }; - yield return new object[] { "en-MP", "M/d/yyyy" }; - yield return new object[] { "en-MS", "dd/MM/yyyy" }; - yield return new object[] { "en-MT", "dd/MM/yyyy" }; - yield return new object[] { "en-MU", "dd/MM/yyyy" }; - yield return new object[] { "en-MW", "dd/MM/yyyy" }; - yield return new object[] { "en-MY", "dd/MM/yyyy" }; - yield return new object[] { "en-NA", "dd/MM/yyyy" }; - yield return new object[] { "en-NF", "dd/MM/yyyy" }; - yield return new object[] { "en-NG", "dd/MM/yyyy" }; - yield return new object[] { "en-NL", "dd/MM/yyyy" }; - yield return new object[] { "en-NR", "dd/MM/yyyy" }; - yield return new object[] { "en-NU", "dd/MM/yyyy" }; - yield return new object[] { "en-NZ", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "d/MM/yyyy" : "dd/MM/yyyy" }; // "d/MM/yyyy" - yield return new object[] { "en-PG", "dd/MM/yyyy" }; - yield return new object[] { "en-PH", "M/d/yyyy" }; // "dd/MM/yyyy" - yield return new object[] { "en-PK", "dd/MM/yyyy" }; - yield return new object[] { "en-PN", "dd/MM/yyyy" }; - yield return new object[] { "en-PR", "M/d/yyyy" }; - yield return new object[] { "en-PW", "dd/MM/yyyy" }; - yield return new object[] { "en-RW", "dd/MM/yyyy" }; - yield return new object[] { "en-SB", "dd/MM/yyyy" }; - yield return new object[] { "en-SC", "dd/MM/yyyy" }; - yield return new object[] { "en-SD", "dd/MM/yyyy" }; - yield return new object[] { "en-SE", "yyyy-MM-dd" }; - yield return new object[] { "en-SG", "d/M/yyyy" }; - yield return new object[] { "en-SH", "dd/MM/yyyy" }; - yield return new object[] { "en-SI", "dd/MM/yyyy" }; - yield return new object[] { "en-SL", "dd/MM/yyyy" }; - yield return new object[] { "en-SS", "dd/MM/yyyy" }; - yield return new object[] { "en-SX", "dd/MM/yyyy" }; - yield return new object[] { "en-SZ", "dd/MM/yyyy" }; - yield return new object[] { "en-TC", "dd/MM/yyyy" }; - yield return new object[] { "en-TK", "dd/MM/yyyy" }; - yield return new object[] { "en-TO", "dd/MM/yyyy" }; - yield return new object[] { "en-TT", "dd/MM/yyyy" }; - yield return new object[] { "en-TV", "dd/MM/yyyy" }; - yield return new object[] { "en-TZ", "dd/MM/yyyy" }; - yield return new object[] { "en-UG", "dd/MM/yyyy" }; - yield return new object[] { "en-UM", "M/d/yyyy" }; - yield return new object[] { "en-US", "M/d/yyyy" }; - yield return new object[] { "en-VC", "dd/MM/yyyy" }; - yield return new object[] { "en-VG", "dd/MM/yyyy" }; - yield return new object[] { "en-VI", "M/d/yyyy" }; - yield return new object[] { "en-VU", "dd/MM/yyyy" }; - yield return new object[] { "en-WS", "dd/MM/yyyy" }; - yield return new object[] { "en-ZA", "yyyy/MM/dd" }; - yield return new object[] { "en-ZM", "dd/MM/yyyy" }; - yield return new object[] { "en-ZW", "d/M/yyyy" }; - yield return new object[] { "es-419", "d/M/yyyy" }; - yield return new object[] { "es-ES", "d/M/yyyy" }; - yield return new object[] { "es-MX", "dd/MM/yyyy" }; - yield return new object[] { "et-EE", "dd.MM.yyyy" }; - yield return new object[] { "fa-IR", "yyyy/M/d" }; // "yyyy/M/d" - yield return new object[] { "fi-FI", "d.M.yyyy" }; - yield return new object[] { "fil-PH", "M/d/yyyy" }; - yield return new object[] { "fr-BE", "d/MM/yyyy" }; - yield return new object[] { "fr-CA", "yyyy-MM-dd" }; - yield return new object[] { "fr-CH", "dd.MM.yyyy" }; - yield return new object[] { "fr-FR", "dd/MM/yyyy" }; - yield return new object[] { "gu-IN", "d/M/yyyy" }; - yield return new object[] { "he-IL", "d.M.yyyy" }; - yield return new object[] { "hi-IN", "d/M/yyyy" }; - yield return new object[] { "hr-BA", "d. M. yyyy." }; - yield return new object[] { "hr-HR", "dd. MM. yyyy." }; - yield return new object[] { "hu-HU", "yyyy. MM. dd." }; - yield return new object[] { "id-ID", "dd/MM/yyyy" }; - yield return new object[] { "it-CH", "dd.MM.yyyy" }; - yield return new object[] { "it-IT", "dd/MM/yyyy" }; - yield return new object[] { "ja-JP", "yyyy/MM/dd" }; - yield return new object[] { "kn-IN", "d/M/yyyy" }; - yield return new object[] { "ko-KR", "yyyy. M. d." }; - yield return new object[] { "lt-LT", "yyyy-MM-dd" }; - yield return new object[] { "lv-LV", "dd.MM.yyyy" }; - yield return new object[] { "ml-IN", "d/M/yyyy" }; - yield return new object[] { "mr-IN", "d/M/yyyy" }; - yield return new object[] { "ms-BN", "d/MM/yyyy" }; - yield return new object[] { "ms-MY", "d/MM/yyyy" }; - yield return new object[] { "ms-SG", "d/MM/yyyy" }; - yield return new object[] { "nb-NO", "dd.MM.yyyy" }; - yield return new object[] { "no", "dd.MM.yyyy" }; - yield return new object[] { "no-NO", "dd.MM.yyyy" }; - yield return new object[] { "nl-AW", "dd-MM-yyyy" }; - yield return new object[] { "nl-BE", "d/MM/yyyy" }; - yield return new object[] { "nl-NL", "dd-MM-yyyy" }; - yield return new object[] { "pl-PL", "d.MM.yyyy" }; // "dd.MM.yyyy" - yield return new object[] { "pt-BR", "dd/MM/yyyy" }; - yield return new object[] { "pt-PT", "dd/MM/yyyy" }; - yield return new object[] { "ro-RO", "dd.MM.yyyy" }; - yield return new object[] { "ru-RU", "dd.MM.yyyy" }; - yield return new object[] { "sk-SK", "d. M. yyyy" }; - yield return new object[] { "sl-SI", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "d. MM. yyyy" : "d. M. yyyy" }; // "d. MM. yyyy" - yield return new object[] { "sr-Cyrl-RS", "d.M.yyyy." }; - yield return new object[] { "sr-Latn-RS", "d.M.yyyy." }; - yield return new object[] { "sv-AX", "yyyy-MM-dd" }; - yield return new object[] { "sv-SE", "yyyy-MM-dd" }; - yield return new object[] { "sw-CD", "dd/MM/yyyy" }; - yield return new object[] { "sw-KE", "dd/MM/yyyy" }; - yield return new object[] { "sw-TZ", "dd/MM/yyyy" }; - yield return new object[] { "sw-UG", "dd/MM/yyyy" }; - yield return new object[] { "ta-IN", "d/M/yyyy" }; - yield return new object[] { "ta-LK", "d/M/yyyy" }; - yield return new object[] { "ta-MY", "d/M/yyyy" }; - yield return new object[] { "ta-SG", "d/M/yyyy" }; - yield return new object[] { "te-IN", "dd-MM-yyyy" }; - yield return new object[] { "th-TH", "d/M/yyyy" }; - yield return new object[] { "tr-CY", "d.MM.yyyy" }; - yield return new object[] { "tr-TR", "d.MM.yyyy" }; - yield return new object[] { "uk-UA", "dd.MM.yyyy" }; - yield return new object[] { "vi-VN", PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "dd/MM/yyyy" : "d/M/yyyy" }; // "dd/MM/yyyy" - yield return new object[] { "zh-CN", "yyyy/M/d" }; - yield return new object[] { "zh-Hans-HK", "d/M/yyyy" }; - yield return new object[] { "zh-SG", "dd/MM/yyyy" }; - yield return new object[] { "zh-HK", "d/M/yyyy" }; - yield return new object[] { "zh-TW", "yyyy/M/d" }; - } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization))] [MemberData(nameof(ShortDatePattern_Get_TestData_ICU))] public void ShortDatePattern_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, string expected) @@ -212,14 +21,6 @@ public void ShortDatePattern_Get_ReturnsExpected_ICU(DateTimeFormatInfo format, Assert.Equal(expected, format.ShortDatePattern); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(ShortDatePattern_Get_TestData_HybridGlobalization))] - public void ShortDatePattern_Get_ReturnsExpected_HybridGlobalization(string cultureName, string expected) - { - var format = new CultureInfo(cultureName).DateTimeFormat; - Assert.True(expected == format.ShortDatePattern, $"Failed for culture: {cultureName}. Expected: {expected}, Actual: {format.ShortDatePattern}"); - } - [Fact] public void ShortDatePattern_InvariantInfo() { diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortTimePattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortTimePattern.cs index d806e19b7502c..a3d73485f074a 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortTimePattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortTimePattern.cs @@ -14,205 +14,6 @@ public void ShortTimePattern_GetInvariantInfo_ReturnsExpected() Assert.Equal("HH:mm", DateTimeFormatInfo.InvariantInfo.ShortTimePattern); } - public static IEnumerable ShortTimePattern_Get_TestData_HybridGlobalization() - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, "H:mm" }; // HH:mm - yield return new object[] { new CultureInfo("bn-BD").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, "HH.mm" }; - yield return new object[] { new CultureInfo("de-AT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-BE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-CH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-DE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-IT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-LI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("el-GR").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-AE").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-AG").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-AI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-AS").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-AT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-BB").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-BE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-BI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-BM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-BS").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-BW").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-BZ").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CA").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-CC").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CK").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CM").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CX").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-CY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-DE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-DK").DateTimeFormat, "HH.mm" }; - yield return new object[] { new CultureInfo("en-DM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-ER").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-FI").DateTimeFormat, "H.mm" }; - yield return new object[] { new CultureInfo("en-FJ").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-FK").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-FM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-GD").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-GG").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-GH").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-GI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-GM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-GU").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-GY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-HK").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-IE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-IL").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("en-IM").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-IO").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-JE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-JM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-KE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-KI").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-KN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-KY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-LC").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-LR").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-LS").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-MG").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-MH").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-MO").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-MP").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-MS").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-MT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-MU").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-MW").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-MY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-NA").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-NF").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-NG").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-NL").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-NR").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-NU").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-NZ").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-PG").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-PH").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-PK").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-PN").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-PR").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-PW").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-RW").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SB").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-SC").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SD").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-SE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SG").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-SH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SL").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-SS").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-SX").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-SZ").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-TC").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-TK").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-TO").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-TT").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-TV").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-TZ").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-UG").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-UM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-VC").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-VG").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-VI").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-VU").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-WS").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-ZA").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-ZM").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("en-ZW").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("en-US").DateTimeFormat, "h:mm tt" }; - string latinAmericanSpanishPattern = PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "HH:mm" : "h:mm tt"; // "HH:mm" - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, latinAmericanSpanishPattern }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, latinAmericanSpanishPattern }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, "H.mm" }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("fr-BE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, "HH 'h' mm 'min'" }; // HH 'h' mm - yield return new object[] { new CultureInfo("fr-CH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, "hh:mm tt" }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, "HH.mm" }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("it-IT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, "hh:mm tt" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "tt h:mm" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("mr-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("ms-MY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("ms-SG").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("no-NO").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("nl-AW").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("nl-BE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("pt-BR").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, "H:mm" }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sv-AX").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sv-SE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sw-KE").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sw-TZ").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("sw-UG").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, "tt h:mm" }; - yield return new object[] { new CultureInfo("ta-LK").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("ta-MY").DateTimeFormat, "tt h:mm" }; - yield return new object[] { new CultureInfo("ta-SG").DateTimeFormat, "tt h:mm" }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, "h:mm tt" }; - yield return new object[] { new CultureInfo("tr-TR").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "HH:mm" }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, "HH:mm" }; // tth:mm - yield return new object[] { new CultureInfo("zh-Hans-HK").DateTimeFormat, "tth:mm" }; - yield return new object[] { new CultureInfo("zh-SG").DateTimeFormat, "tth:mm" }; - yield return new object[] { new CultureInfo("zh-HK").DateTimeFormat, "tth:mm" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "tth:mm" }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(ShortTimePattern_Get_TestData_HybridGlobalization))] - public void ShortTimePattern_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string value) - { - Assert.Equal(value, format.ShortTimePattern); - } - public static IEnumerable ShortTimePattern_Set_TestData() { yield return new object[] { string.Empty }; diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortestDayNames.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortestDayNames.cs index f99c694d3bb2f..6e8d620a50102 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortestDayNames.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoShortestDayNames.cs @@ -28,76 +28,6 @@ public static IEnumerable ShortestDayNames_Set_TestData() yield return new object[] { new string[] { "", "", "", "", "", "", "" } }; } - public static IEnumerable ShortestDayNames_Get_TestData_HybridGlobalization() - { - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, new string[] { "ح", "ن", "ث", "ر", "خ", "ج", "س" } }; - yield return new object[] { new CultureInfo("am-ET").DateTimeFormat, new string[] { "እ", "ሰ", "ማ", "ረ", "ሐ", "ዓ", "ቅ" } }; - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, new string[] { "н", "п", "в", "с", "ч", "п", "с" } }; - yield return new object[] { new CultureInfo("bn-IN").DateTimeFormat, new string[] { "র", "সো", "ম", "বু", "বৃ", "শু", "শ" } }; - if (PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS) - { - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, new string[] { "dg", "dl", "dt", "dc", "dj", "dv", "ds" } }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, new string[] { "Su.", "M.", "Tu.", "W.", "Th.", "F.", "Sa." } }; - } - else - { - yield return new object[] { new CultureInfo("ca-ES").DateTimeFormat, new string[] { "dg.", "dl.", "dt.", "dc.", "dj.", "dv.", "ds." } }; - yield return new object[] { new CultureInfo("en-AU").DateTimeFormat, new string[] { "S", "M", "T", "W", "T", "F", "S" } }; // "Su.", "M.", "Tu.", "W.", "Th.", "F.", "Sa." - } - - yield return new object[] { new CultureInfo("cs-CZ").DateTimeFormat, new string[] { "N", "P", "Ú", "S", "Č", "P", "S" } }; - yield return new object[] { new CultureInfo("da-DK").DateTimeFormat, new string[] { "S", "M", "T", "O", "T", "F", "L" } }; - yield return new object[] { new CultureInfo("de-LU").DateTimeFormat, new string[] { "S", "M", "D", "M", "D", "F", "S" } }; - yield return new object[] { new CultureInfo("el-CY").DateTimeFormat, new string[] { "Κ", "Δ", "Τ", "Τ", "Π", "Π", "Σ" } }; - yield return new object[] { new CultureInfo("en-GB").DateTimeFormat, new string[] { "S", "M", "T", "W", "T", "F", "S" } }; - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, new string[] { "D", "L", "M", "M", "J", "V", "S" } }; - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, new string[] { "D", "L", "M", "X", "J", "V", "S" } }; - yield return new object[] { new CultureInfo("et-EE").DateTimeFormat, new string[] { "P", "E", "T", "K", "N", "R", "L" } }; - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, new string[] { "ی", "د", "س", "چ", "پ", "ج", "ش" } }; - yield return new object[] { new CultureInfo("fi-FI").DateTimeFormat, new string[] { "S", "M", "T", "K", "T", "P", "L" } }; - yield return new object[] { new CultureInfo("fil-PH").DateTimeFormat, new string[] { "Lin", "Lun", "Mar", "Miy", "Huw", "Biy", "Sab" } }; - yield return new object[] { new CultureInfo("fr-CA").DateTimeFormat, new string[] { "D", "L", "M", "M", "J", "V", "S" } }; - yield return new object[] { new CultureInfo("gu-IN").DateTimeFormat, new string[] { "ર", "સો", "મં", "બુ", "ગુ", "શુ", "શ" } }; - yield return new object[] { new CultureInfo("he-IL").DateTimeFormat, new string[] { "א׳", "ב׳", "ג׳", "ד׳", "ה׳", "ו׳", "ש׳" } }; - yield return new object[] { new CultureInfo("hi-IN").DateTimeFormat, new string[] { "र", "सो", "मं", "बु", "गु", "शु", "श" } }; - yield return new object[] { new CultureInfo("hr-BA").DateTimeFormat, new string[] { "N", "P", "U", "S", "Č", "P", "S" } }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, new string[] { "n", "p", "u", "s", "č", "p", "s" } }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, new string[] { "V", "H", "K", "Sz", "Cs", "P", "Sz" } }; - yield return new object[] { new CultureInfo("id-ID").DateTimeFormat, new string[] { "M", "S", "S", "R", "K", "J", "S" } }; - yield return new object[] { new CultureInfo("it-CH").DateTimeFormat, new string[] { "D", "L", "M", "M", "G", "V", "S" } }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, new string[] { "日", "月", "火", "水", "木", "金", "土" } }; - yield return new object[] { new CultureInfo("kn-IN").DateTimeFormat, new string[] { "ಭಾ", "ಸೋ", "ಮಂ", "ಬು", "ಗು", "ಶು", "ಶ" } }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, new string[] { "일", "월", "화", "수", "목", "금", "토" } }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, new string[] { "S", "P", "A", "T", "K", "P", "Š" } }; - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, new string[] { "S", "P", "O", "T", "C", "P", "S" } }; - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, new string[] { "ഞാ", "തി", "ചൊ", "ബു", "വ്യാ", "വെ", "ശ" } }; - yield return new object[] { new CultureInfo("ms-BN").DateTimeFormat, new string[] { "A", "I", "S", "R", "K", "J", "S" } }; - yield return new object[] { new CultureInfo("nb-NO").DateTimeFormat, new string[] { "S", "M", "T", "O", "T", "F", "L" } }; - yield return new object[] { new CultureInfo("nl-NL").DateTimeFormat, new string[] { "Z", "M", "D", "W", "D", "V", "Z" } }; - yield return new object[] { new CultureInfo("pl-PL").DateTimeFormat, new string[] { "N", "P", "W", "Ś", "C", "P", "S" } }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, new string[] { "D", "S", "T", "Q", "Q", "S", "S" } }; - yield return new object[] { new CultureInfo("ro-RO").DateTimeFormat, new string[] { "D", "L", "M", "M", "J", "V", "S" } }; - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, new string[] { "В", "П", "В", "С", "Ч", "П", "С" } }; - yield return new object[] { new CultureInfo("sk-SK").DateTimeFormat, new string[] { "n", "p", "u", "s", "š", "p", "s" } }; - yield return new object[] { new CultureInfo("sl-SI").DateTimeFormat, new string[] { "n", "p", "t", "s", "č", "p", "s" } }; - yield return new object[] { new CultureInfo("sr-Cyrl-RS").DateTimeFormat, new string[] { "н", "п", "у", "с", "ч", "п", "с" } }; - yield return new object[] { new CultureInfo("sw-CD").DateTimeFormat, new string[] { "S", "M", "T", "W", "T", "F", "S" } }; - yield return new object[] { new CultureInfo("ta-IN").DateTimeFormat, new string[] { "ஞா", "தி", "செ", "பு", "வி", "வெ", "ச" } }; - yield return new object[] { new CultureInfo("te-IN").DateTimeFormat, new string[] { "ఆ", "సో", "మ", "బు", "గు", "శు", "శ" } }; - yield return new object[] { new CultureInfo("th-TH").DateTimeFormat, new string[] { "อา", "จ", "อ", "พ", "พฤ", "ศ", "ส" } }; - yield return new object[] { new CultureInfo("tr-CY").DateTimeFormat, new string[] { "P", "P", "S", "Ç", "P", "C", "C" } }; - yield return new object[] { new CultureInfo("uk-UA").DateTimeFormat, new string[] { "Н", "П", "В", "С", "Ч", "П", "С" } }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, new string[] { "CN", "T2", "T3", "T4", "T5", "T6", "T7" } }; - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, new string[] { "日", "一", "二", "三", "四", "五", "六" } }; - } - - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] - [MemberData(nameof(ShortestDayNames_Get_TestData_HybridGlobalization))] - public void ShortestDayNames_Get_ReturnsExpected_HybridGlobalization(DateTimeFormatInfo format, string[] expected) - { - Assert.Equal(expected, format.ShortestDayNames); - } - [Theory] [MemberData(nameof(ShortestDayNames_Set_TestData))] public void ShortestDayNames_Set_GetReturnsExpected(string[] value) diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoTests.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoTests.cs index 6e00c34d4ca92..991e05f1f4f90 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoTests.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoTests.cs @@ -138,7 +138,7 @@ public void GetShortestDayName_Invoke_ReturnsExpected(string cultureName) } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [Fact] public void Months_GetHebrew_ReturnsExpected() { CultureInfo ci = new CultureInfo("he-IL"); diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoYearMonthPattern.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoYearMonthPattern.cs index 4c4d01b957b40..53c0028bf3c7b 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoYearMonthPattern.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/DateTimeFormatInfo/DateTimeFormatInfoYearMonthPattern.cs @@ -12,30 +12,6 @@ public static IEnumerable YearMonthPattern_Get_TestData() { yield return new object[] { DateTimeFormatInfo.InvariantInfo, "yyyy MMMM" }; yield return new object[] { new CultureInfo("fr-FR").DateTimeFormat, "MMMM yyyy" }; - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - // see the comments on the right to check the non-Hybrid result, if it differs - yield return new object[] { new CultureInfo("ar-SA").DateTimeFormat, "MMMM yyyy" }; // "MMMM yyyy g" - yield return new object[] { new CultureInfo("bg-BG").DateTimeFormat, "MMMM yyyy \u0433." }; // ICU: "MMMM yyyy '\u0433'." - yield return new object[] { new CultureInfo("ca-AD").DateTimeFormat, PlatformDetection.IsFirefox || PlatformDetection.IsNodeJS ? "MMMM de yyyy" : "MMMM del yyyy" }; // ICU: "MMMM 'de' yyyy" - yield return new object[] { new CultureInfo("es-419").DateTimeFormat, "MMMM de yyyy" }; // ICU: "MMMM 'de' yyyy" - yield return new object[] { new CultureInfo("es-ES").DateTimeFormat, "MMMM de yyyy" }; // ICU: "MMMM 'de' yyyy" - yield return new object[] { new CultureInfo("es-MX").DateTimeFormat, "MMMM de yyyy" }; // ICU: "MMMM 'de' yyyy" - yield return new object[] { new CultureInfo("fa-IR").DateTimeFormat, "yyyy MMMM" }; - yield return new object[] { new CultureInfo("hr-HR").DateTimeFormat, "MMMM yyyy." }; - yield return new object[] { new CultureInfo("hu-HU").DateTimeFormat, "yyyy. MMMM" }; - yield return new object[] { new CultureInfo("ja-JP").DateTimeFormat, "yyyy\u5e74M\u6708" }; - yield return new object[] { new CultureInfo("ko-KR").DateTimeFormat, "yyyy\ub144 MMMM" }; - yield return new object[] { new CultureInfo("lt-LT").DateTimeFormat, "yyyy m. MMMM" }; // ICU: "yyyy 'm'. MMMM" - yield return new object[] { new CultureInfo("lv-LV").DateTimeFormat, "yyyy. g. MMMM" }; // ICU: "yyyy. 'g'. MMMM" - yield return new object[] { new CultureInfo("ml-IN").DateTimeFormat, "yyyy MMMM" }; - yield return new object[] { new CultureInfo("pt-PT").DateTimeFormat, "MMMM de yyyy" }; // ICU: "MMMM 'de' yyyy" - yield return new object[] { new CultureInfo("ru-RU").DateTimeFormat, "MMMM yyyy \u0433." }; // ICU: "MMMM yyyy '\u0433'." - yield return new object[] { new CultureInfo("sr-Latn-RS").DateTimeFormat, "MMMM yyyy." }; - yield return new object[] { new CultureInfo("vi-VN").DateTimeFormat, "MMMM n\u0103m yyyy" }; // ICU: "MMMM 'n\u0103m' yyyy" - yield return new object[] { new CultureInfo("zh-CN").DateTimeFormat, "yyyy\u5e74M\u6708" }; - yield return new object[] { new CultureInfo("zh-TW").DateTimeFormat, "yyyy\u5e74M\u6708" }; - } } [Theory] diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/Hybrid/System.Globalization.Hybrid.WASM.Tests.csproj b/src/libraries/System.Runtime/tests/System.Globalization.Tests/Hybrid/System.Globalization.Hybrid.WASM.Tests.csproj deleted file mode 100644 index 8c90eef092f03..0000000000000 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/Hybrid/System.Globalization.Hybrid.WASM.Tests.csproj +++ /dev/null @@ -1,61 +0,0 @@ - - - $(NetCoreAppCurrent)-browser - true - true - true - true - - - - WasmTestOnChrome - $(TestArchiveRoot)browseronly/ - $(TestArchiveTestsRoot)$(OSPlatformConfig)/ - $(DefineConstants);TARGET_BROWSER - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/src/libraries/System.Runtime/tests/System.Globalization.Tests/System/Globalization/TextInfoTests.cs b/src/libraries/System.Runtime/tests/System.Globalization.Tests/System/Globalization/TextInfoTests.cs index 466be98c442d9..924de536b6efb 100644 --- a/src/libraries/System.Runtime/tests/System.Globalization.Tests/System/Globalization/TextInfoTests.cs +++ b/src/libraries/System.Runtime/tests/System.Globalization.Tests/System/Globalization/TextInfoTests.cs @@ -274,15 +274,7 @@ public static IEnumerable ToLower_TestData() // we also don't preform. // Greek Capital Letter Sigma (does not case to U+03C2 with "final sigma" rule). yield return new object[] { cultureName, "\u03A3", "\u03C3" }; - if (PlatformDetection.IsHybridGlobalizationOnBrowser) - { - // JS is using "final sigma" rule correctly - it's costly to unify it with ICU's behavior - yield return new object[] { cultureName, "O\u03A3", "o\u03C2" }; - } - else - { - yield return new object[] { cultureName, "O\u03A3", "o\u03C3" }; - } + yield return new object[] { cultureName, "O\u03A3", "o\u03C3" }; } foreach (string cultureName in GetTestLocales()) diff --git a/src/libraries/System.Runtime/tests/System.Runtime.Extensions.Tests/System/StringComparer.cs b/src/libraries/System.Runtime/tests/System.Runtime.Extensions.Tests/System/StringComparer.cs index bb69f0df97a3e..fa2a92c932cef 100644 --- a/src/libraries/System.Runtime/tests/System.Runtime.Extensions.Tests/System/StringComparer.cs +++ b/src/libraries/System.Runtime/tests/System.Runtime.Extensions.Tests/System/StringComparer.cs @@ -87,8 +87,7 @@ public static IEnumerable UpperLowerCasing_TestData() yield return new object[] { "abcd", "ABCD", "en-US" }; yield return new object[] { "latin i", "LATIN I", "en-US" }; - // https://github.com/dotnet/runtime/issues/95503 - if (PlatformDetection.IsNotInvariantGlobalization && PlatformDetection.IsNotHybridGlobalizationOnBrowser && !PlatformDetection.IsAndroid && !PlatformDetection.IsLinuxBionic) + if (PlatformDetection.IsNotInvariantGlobalization && !PlatformDetection.IsAndroid && !PlatformDetection.IsLinuxBionic) { yield return new object[] { "turky \u0131", "TURKY I", "tr-TR" }; yield return new object[] { "turky i", "TURKY \u0130", "tr-TR" }; @@ -182,12 +181,11 @@ public static IEnumerable CreateFromCultureAndOptionsData() if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) { - bool ignoreSymbolsIgnoresOnlyPunctuation = PlatformDetection.IsHybridGlobalizationOnBrowser; yield return new object[] { "abcd", "ab cd", "en-US", CompareOptions.IgnoreSymbols, true }; - yield return new object[] { "abcd", "ab+cd", "en-US", CompareOptions.IgnoreSymbols, !ignoreSymbolsIgnoresOnlyPunctuation }; + yield return new object[] { "abcd", "ab+cd", "en-US", CompareOptions.IgnoreSymbols, true }; yield return new object[] { "abcd", "ab%cd", "en-US", CompareOptions.IgnoreSymbols, true }; yield return new object[] { "abcd", "ab&cd", "en-US", CompareOptions.IgnoreSymbols, true }; - yield return new object[] { "abcd", "ab$cd", "en-US", CompareOptions.IgnoreSymbols, !ignoreSymbolsIgnoresOnlyPunctuation }; + yield return new object[] { "abcd", "ab$cd", "en-US", CompareOptions.IgnoreSymbols, true }; yield return new object[] { "a-bcd", "ab$cd", "en-US", CompareOptions.IgnoreSymbols, true }; yield return new object[] { "abcd*", "ab$cd", "en-US", CompareOptions.IgnoreSymbols, true }; yield return new object[] { "ab$dd", "ab$cd", "en-US", CompareOptions.IgnoreSymbols, false }; @@ -200,7 +198,7 @@ public static IEnumerable CreateFromCultureAndOptionsData() { "abcd", "ABcd", "en-US", CompareOptions.StringSort, false }, }; - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] [MemberData(nameof(CreateFromCultureAndOptionsData))] [MemberData(nameof(CreateFromCultureAndOptionsStringSortData))] public static void CreateFromCultureAndOptions(string actualString, string expectedString, string cultureName, CompareOptions options, bool result) @@ -212,7 +210,7 @@ public static void CreateFromCultureAndOptions(string actualString, string expec Assert.Equal(result, sc.Equals((object)actualString, (object)expectedString)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization))] [MemberData(nameof(CreateFromCultureAndOptionsData))] public static void CreateFromCultureAndOptionsStringSort(string actualString, string expectedString, string cultureName, CompareOptions options, bool result) { diff --git a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringGetHashCodeTests.cs b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringGetHashCodeTests.cs index d6af781605acc..ab646a0941162 100644 --- a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringGetHashCodeTests.cs +++ b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringGetHashCodeTests.cs @@ -91,7 +91,7 @@ public static IEnumerable GetHashCodeOrdinalIgnoreCase_TestData() yield return new object[] { "AaBbCcDdEeFfGgHh".Insert(i, "\u00E9" /* LATIN SMALL LETTER E WITH ACUTE */) }; yield return new object[] { "AaBbCcDdEeFfGgHh".Insert(i, "\u044D" /* CYRILLIC SMALL LETTER E */) }; // https://github.com/dotnet/runtime/issues/95503 - if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform && PlatformDetection.IsNotHybridGlobalizationOnBrowser) + if (PlatformDetection.IsNotHybridGlobalizationOnApplePlatform) yield return new object[] { "AaBbCcDdEeFfGgHh".Insert(i, "\u0131" /* LATIN SMALL LETTER DOTLESS I */) }; } diff --git a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringTests.cs b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringTests.cs index 230ede85d79e0..c512ac077c86a 100644 --- a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringTests.cs +++ b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/StringTests.cs @@ -781,21 +781,17 @@ public static IEnumerable Replace_StringComparison_TestData() { yield return new object[] { "abc", "abc" + SoftHyphen, "def", StringComparison.InvariantCultureIgnoreCase, "def" }; - // https://github.com/dotnet/runtime/issues/95503 - if (!PlatformDetection.IsHybridGlobalizationOnBrowser) - { - string turkishSource = "\u0069\u0130"; + string turkishSource = "\u0069\u0130"; - yield return new object[] { turkishSource, "\u0069", "a", StringComparison.Ordinal, "a\u0130" }; - yield return new object[] { turkishSource, "\u0069", "a", StringComparison.OrdinalIgnoreCase, "a\u0130" }; - yield return new object[] { turkishSource, "\u0130", "a", StringComparison.Ordinal, "\u0069a" }; - yield return new object[] { turkishSource, "\u0130", "a", StringComparison.OrdinalIgnoreCase, "\u0069a" }; + yield return new object[] { turkishSource, "\u0069", "a", StringComparison.Ordinal, "a\u0130" }; + yield return new object[] { turkishSource, "\u0069", "a", StringComparison.OrdinalIgnoreCase, "a\u0130" }; + yield return new object[] { turkishSource, "\u0130", "a", StringComparison.Ordinal, "\u0069a" }; + yield return new object[] { turkishSource, "\u0130", "a", StringComparison.OrdinalIgnoreCase, "\u0069a" }; - yield return new object[] { turkishSource, "\u0069", "a", StringComparison.InvariantCulture, "a\u0130" }; - yield return new object[] { turkishSource, "\u0069", "a", StringComparison.InvariantCultureIgnoreCase, "a\u0130" }; - yield return new object[] { turkishSource, "\u0130", "a", StringComparison.InvariantCulture, "\u0069a" }; - yield return new object[] { turkishSource, "\u0130", "a", StringComparison.InvariantCultureIgnoreCase, "\u0069a" }; - } + yield return new object[] { turkishSource, "\u0069", "a", StringComparison.InvariantCulture, "a\u0130" }; + yield return new object[] { turkishSource, "\u0069", "a", StringComparison.InvariantCultureIgnoreCase, "a\u0130" }; + yield return new object[] { turkishSource, "\u0130", "a", StringComparison.InvariantCulture, "\u0069a" }; + yield return new object[] { turkishSource, "\u0130", "a", StringComparison.InvariantCultureIgnoreCase, "\u0069a" }; } // To catch regressions when dealing with zero-length "this" inputs @@ -804,8 +800,8 @@ public static IEnumerable Replace_StringComparison_TestData() yield return new object[] { "", "\0", "y", StringComparison.InvariantCulture, "" }; } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] - [MemberData(nameof(Replace_StringComparison_TestData))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] + [MemberData(nameof(Replace_StringComparison_TestData))] public void Replace_StringComparison_ReturnsExpected(string original, string oldValue, string newValue, StringComparison comparisonType, string expected) { Assert.Equal(expected, original.Replace(oldValue, newValue, comparisonType)); @@ -813,7 +809,6 @@ public void Replace_StringComparison_ReturnsExpected(string original, string old [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] [ActiveIssue("https://github.com/dotnet/runtime/issues/60568", TestPlatforms.Android | TestPlatforms.LinuxBionic)] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95503", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public void Replace_StringComparison_TurkishI() { const string Source = "\u0069\u0130"; @@ -873,7 +868,6 @@ public static IEnumerable Replace_StringComparisonCulture_TestData() [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] [MemberData(nameof(Replace_StringComparisonCulture_TestData))] - [ActiveIssue("https://github.com/dotnet/runtime/issues/95503", typeof(PlatformDetection), nameof(PlatformDetection.IsHybridGlobalizationOnBrowser))] public void Replace_StringComparisonCulture_ReturnsExpected(string original, string oldValue, string newValue, bool ignoreCase, CultureInfo culture, string expected) { Assert.Equal(expected, original.Replace(oldValue, newValue, ignoreCase, culture)); @@ -897,7 +891,7 @@ public void Replace_StringComparison_EmptyOldValue_ThrowsArgumentException() AssertExtensions.Throws("oldValue", () => "abc".Replace("", "def", true, CultureInfo.CurrentCulture)); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] + [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] public void Replace_StringComparison_WeightlessOldValue_WithOrdinalComparison_Succeeds() { Assert.Equal("abcdef", ("abc" + ZeroWidthJoiner).Replace(ZeroWidthJoiner, "def")); @@ -905,7 +899,7 @@ public void Replace_StringComparison_WeightlessOldValue_WithOrdinalComparison_Su Assert.Equal("abcdef", ("abc" + ZeroWidthJoiner).Replace(ZeroWidthJoiner, "def", StringComparison.OrdinalIgnoreCase)); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnBrowser), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] + [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotInvariantGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] public void Replace_StringComparison_WeightlessOldValue_WithLinguisticComparison_TerminatesReplacement() { Assert.Equal("abc" + ZeroWidthJoiner + "def", ("abc" + ZeroWidthJoiner + "def").Replace(ZeroWidthJoiner, "xyz", StringComparison.CurrentCulture)); diff --git a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/Text/RuneTests.cs b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/Text/RuneTests.cs index 578d09f3eaad6..cac581e03e360 100644 --- a/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/Text/RuneTests.cs +++ b/src/libraries/System.Runtime/tests/System.Runtime.Tests/System/Text/RuneTests.cs @@ -57,9 +57,8 @@ public static void Casing_Invariant(int original, int upper, int lower) Assert.Equal(new Rune(lower), Rune.ToLowerInvariant(rune)); } - [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalizationAndNotHybridOnBrowser), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] + [ConditionalTheory(typeof(PlatformDetection), nameof(PlatformDetection.IsIcuGlobalization), nameof(PlatformDetection.IsNotHybridGlobalizationOnApplePlatform))] // HybridGlobalization on Apple mobile platforms has issues with casing dotless I - // HybridGlobalization on Browser uses Invariant HashCode and SortKey, so its effect does not match this of ICU [InlineData('0', '0', '0')] [InlineData('a', 'A', 'a')] [InlineData('i', 'I', 'i')] diff --git a/src/libraries/tests.proj b/src/libraries/tests.proj index a30405c85421d..fae36df0a3f5b 100644 --- a/src/libraries/tests.proj +++ b/src/libraries/tests.proj @@ -83,12 +83,6 @@ - - - - - - @@ -394,12 +388,6 @@ - - - - - - diff --git a/src/mono/browser/README.md b/src/mono/browser/README.md index 202f36683e040..ca9e5893a50f3 100644 --- a/src/mono/browser/README.md +++ b/src/mono/browser/README.md @@ -319,14 +319,12 @@ npm update --lockfile-version=1 * `runtime-wasm*` pipelines are triggered manually, and they only run the jobs that would not run on any default pipelines based on path changes. * The `AOT` jobs run only smoke tests on `runtime`, and on `runtime-wasm*` pipelines all the `AOT` tests are run. -* HG libtests are library test with `HybridGlobalization=true` | . | runtime-wasm | runtime-wasm-libtests | runtime-wasm-non-libtests | | ----------------- | -------------------------- | -------------------- | -------------------- | | libtests | linux+windows: all | linux+windows: all | none | | libtests eat | linux: all | linux: all | none | | libtests aot | linux+windows: all | linux+windows: all | none | -| libtests hg | linux+windows: all | linux+windows: all | none | | high resource aot | linux+windows: all | linux+windows: all | none | | Wasm.Build.Tests | linux+windows | none | linux+windows | | Debugger tests | linux+windows | none | linux+windows | diff --git a/src/mono/wasm/Wasm.Build.Tests/HybridGlobalizationTests.cs b/src/mono/wasm/Wasm.Build.Tests/HybridGlobalizationTests.cs deleted file mode 100644 index 8d1a861dc213c..0000000000000 --- a/src/mono/wasm/Wasm.Build.Tests/HybridGlobalizationTests.cs +++ /dev/null @@ -1,62 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System.Collections.Generic; -using System.IO; -using Xunit; -using Xunit.Abstractions; - -#nullable enable - -namespace Wasm.Build.Tests -{ - public class HybridGlobalizationTests : TestMainJsTestBase - { - public HybridGlobalizationTests(ITestOutputHelper output, SharedBuildPerTestClassFixture buildContext) - : base(output, buildContext) - { - } - - public static IEnumerable HybridGlobalizationTestData(bool aot, RunHost host) - => ConfigWithAOTData(aot) - .WithRunHosts(host) - .UnwrapItemsAsArrays(); - - [Theory] - [MemberData(nameof(HybridGlobalizationTestData), parameters: new object[] { /*aot*/ false, RunHost.All })] - [MemberData(nameof(HybridGlobalizationTestData), parameters: new object[] { /*aot*/ true, RunHost.All })] - public void AOT_HybridGlobalizationTests(BuildArgs buildArgs, RunHost host, string id) - => TestHybridGlobalizationTests(buildArgs, host, id); - - [Theory] - [MemberData(nameof(HybridGlobalizationTestData), parameters: new object[] { /*aot*/ false, RunHost.All })] - public void RelinkingWithoutAOT(BuildArgs buildArgs, RunHost host, string id) - => TestHybridGlobalizationTests(buildArgs, host, id, - extraProperties: "true", - dotnetWasmFromRuntimePack: false); - - private void TestHybridGlobalizationTests(BuildArgs buildArgs, RunHost host, string id, string extraProperties="", bool? dotnetWasmFromRuntimePack=null) - { - string projectName = $"hybrid"; - extraProperties = $"{extraProperties}true"; - - buildArgs = buildArgs with { ProjectName = projectName }; - buildArgs = ExpandBuildArgs(buildArgs, extraProperties); - - if (dotnetWasmFromRuntimePack == null) - dotnetWasmFromRuntimePack = IsDotnetWasmFromRuntimePack(buildArgs); - - string programText = File.ReadAllText(Path.Combine(BuildEnvironment.TestAssetsPath, "Wasm.Buid.Tests.Programs", "HybridGlobalization.cs")); - - BuildProject(buildArgs, - id: id, - new BuildProjectOptions( - InitProject: () => File.WriteAllText(Path.Combine(_projectDir!, "Program.cs"), programText), - DotnetWasmFromRuntimePack: dotnetWasmFromRuntimePack, - GlobalizationMode: GlobalizationMode.Hybrid)); - - string output = RunAndTestWasmApp(buildArgs, expectedExitCode: 42, host: host, id: id); - Assert.Contains("HybridGlobalization works, thrown exception as expected", output); - } - } -} diff --git a/src/mono/wasm/features.md b/src/mono/wasm/features.md index 31d281ba389a1..c13dde952952c 100644 --- a/src/mono/wasm/features.md +++ b/src/mono/wasm/features.md @@ -259,8 +259,6 @@ For some use cases, you may wish to override this behavior or create a custom IC There are also rare use cases where your application does not rely on the contents of the ICU databases. In those scenarios, you can make your application smaller by enabling Invariant Globalization via the `true` msbuild property. For more details see [globalization-invariant-mode.md](../../../docs/design/features/globalization-invariant-mode.md). -We are currently developing a third approach for locales where we offer a more limited feature set by relying on browser APIs, called "Hybrid Globalization". This provides more functionality than Invariant Culture mode without the need to ship the ICU library or its databases, which improves startup time. You can use the msbuild property `true` to test this in-development feature, but be aware that it is currently incomplete and may have performance issues. For more details see [globalization-hybrid-mode.md](../../../docs/design/features/globalization-hybrid-mode.md). - Customized globalization settings require [wasm-tools workload](#wasm-tools-workload) to be installed. ### Timezones