-
Notifications
You must be signed in to change notification settings - Fork 394
Not all tests pass using non-English culture (e.g. Turkish, Korean, German) #1098
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
cc @alatas that I ran all tests using Turkish culture to possibly find more issues. Mostly it seems that PSSA behaves reasonably OK-ish using Turkish culture but there are some test cases that fail that we can look into |
@bergmeister I run all tests in a computer that Turkish culture is set, and 67 of tests are failed. Then, I built the source from ground up and get the same result (Win10 with PS 5.1) I'd happy to help if you need |
@alatas So far I could identify and fix 2 problems and locally all tests are working fine now on Windows PowerShell when I change both the CurrentCulture and CurrentUICulture to Turkish but somehow not in the CI system. You can see those additional improvements in PR #1099. Locally, I see that the locale even matters building and I get a similar failure count to you when I change my culture to Turkish as well, therefore I suspect there are also some .Net Core and PSCore bugs, I will try to isolate now build from runtime problems. |
@bergmeister I use the following commands to test. .\build.ps1 -Clean
.\build.ps1 -Framework full -PSVersion 5 -Configuration Release
Import-Module .\out\PSScriptAnalyzer\PSScriptAnalyzer.psd1
.\build -Test
Import-Module ./build.psm1
Get-TestFailures After the commit 227b64f, 67 failed test drops to 46 in Win10 Powershell 5.1. I downloaded the compiled file and extract it into modules folder, deleted TestResults.xml, Then run the tests again without importing the locally compiled files. But, this approach hasn't changed the results. I changed the failed test resulting scripts a little bit to summarise the results as a csv file. It outputs the failed tests as follows
|
@alatas Thanks, that looks all good. The test failures are probably because you did not build the documentation (i.e. the cmdlet help), hence why the help is missing. You can build the documentation using |
@bergmeister yes, you are right! I built the documentation, and all the tests are succeed 👍 .\build.ps1 -Clean
.\build.ps1 -Framework full -PSVersion 5 -Configuration Release
.\build.ps1 -Documentation
Import-Module .\out\PSScriptAnalyzer\PSScriptAnalyzer.psd1
Remove-Item TestResults.xml -ErrorAction SilentlyContinue
.\build -Test
Import-Module ./build.psm1
Get-TestFailures |
Steps to reproduce
Expected behavior
All Tests pass
Actual behavior
21 tests failed, some of them clearly related to the special i character in Turkish.
The same number of failures also happen using Korean culture
ko-KR
Environment data
This is as of the latest state of development after the first fix of PR 1097 using PowerShell 5.1
The text was updated successfully, but these errors were encountered: