Add Simplified Chinese (zh-CN) GUI translations (#799)

This commit is contained in:
quanfanpro-code
2026-10-11 20:10:21 +02:00
committed by GitHub
parent 17e06614ed
commit e71701c18d
7 changed files with 1800 additions and 6 deletions
+20 -6
View File
@@ -125,13 +125,27 @@ Describe 'Get-PluralCategory' {
Get-PluralCategory -LanguageCode 'en-US' -Count $Count | Should -Be $Expected
}
It 'returns other for a Japanese count of <Count>' -ForEach @(
@{ Count = 0 }
@{ Count = 1 }
@{ Count = 2 }
@{ Count = 5 }
It 'returns other for <LanguageCode> with a count of <Count>' -ForEach @(
foreach ($languageCode in @('ja-JP', 'zh-CN')) {
foreach ($count in @(0, 1, 2, 5, 100)) {
@{ LanguageCode = $languageCode; Count = $count }
}
}
) {
Get-PluralCategory -LanguageCode 'ja-JP' -Count $Count | Should -Be 'other'
Get-PluralCategory -LanguageCode $LanguageCode -Count $Count | Should -Be 'other'
}
It 'returns <Expected> for a Portuguese count of <Count>' -ForEach @(
@{ Count = 0; Expected = 'one' }
@{ Count = 1; Expected = 'one' }
@{ Count = 2; Expected = 'other' }
@{ Count = 100; Expected = 'other' }
@{ Count = 999999; Expected = 'other' }
@{ Count = 1000000; Expected = 'many' }
@{ Count = 1000001; Expected = 'other' }
@{ Count = 2000000; Expected = 'many' }
) {
Get-PluralCategory -LanguageCode 'pt-BR' -Count $Count | Should -Be $Expected
}
}