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
Sanitize localized stack trace in exception tests #9132
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to have this commented, explaining the three manipulations that are done.
It feels like these hardcoded assumptions has a risk of failing in the future (there may be languages that use two words for "at", right-to-left etc).
Draft?
Adjust the log for languages
- Replace Inner exception divider
- Replace the stack trace preposition
- Remove file path (to make compare results)
91edb9c
to
859ad1f
Compare
I have added the comments and noticed that the previous regex contained the preposition "in". |
I want to look at it.
|
Did you try applying the following to the fixture? [SetCulture("en-US")]
[SetUICulture("en-US")] |
859ad1f
to
a294965
Compare
Thank you, it works. |
We set culture for locale sensitive tests. We ought to do the same here,
and avoid custom logic.
|
I did so yesterday. |
I didn't quite grasp the response. Should've opened the diff. Thank you |
Proposed changes
Proposed changes
en-US
inSerializableExceptionTests
Screenshots
Before
After
Test methodology
Test environment(s)
✒️ I contribute this code under The Developer Certificate of Origin.