fix: skip non-ASCII path tests when locale lacks UTF-8 support - #629
Closed
LeonidasZhak wants to merge 1 commit into
Closed
LeonidasZhak wants to merge 1 commit into
LeonidasZhak wants to merge 1 commit into
Conversation
Four tests in test-path.R use Unicode characters in tempfile patterns
but fail on systems where the locale is C (no UTF-8 support), because
tempfile() cannot translate the patterns to the native encoding.
Add skip_if(!l10n_info()$`UTF-8`) guards to these tests:
- can read file w/o final newline, w/ multi-byte characters in path
- can read file w/ final newline, w/ multi-byte characters in path
- can write to path with non-ascii characters
- can read fwf file w/ non-ascii characters in path
Also update _snaps/path.md to match current lifecycle 1.0.5.9000
wording ('in vroom 1.5.0' instead of 'as of vroom 1.5.0').
Author
|
I am withdrawing this PR as part of a broader cleanup of an oversized automated contribution batch. I am sorry for the review noise and the pressure this may have put on maintainers. Going forward I will keep contributions to this project much more limited and higher-signal, ideally only one or two focused PRs at a time. Thank you for maintaining the project. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Four tests in
test-path.Ruse Unicode characters intempfile()patterns but fail on systems where the locale isC(no UTF-8 support), becausetempfile()cannot translate the patterns to the native encoding.This PR adds
skip_if(!l10n_info()$UTF-8)guards to these tests:Also updates
_snaps/path.mdto match current lifecycle 1.0.5.9000 wording (in vroom 1.5.0instead ofas of vroom 1.5.0).Why
On macOS (and other systems) with
LANG=CorLC_CTYPE=C, these tests fail with:The sibling test at line 184 already has a locale guard (
skip_if(l10n_info()$Latin-1)), but the four affected tests had none.Validation
All 4 previously-failing tests now correctly skip on non-UTF-8 locales.