chore(tests): mark sample_file.txt as text with LF line endings - #3879
Open
Yasser-Ameur wants to merge 1 commit into
Open
Yasser-Ameur wants to merge 1 commit into
Yasser-Ameur wants to merge 1 commit into
Conversation
A default Windows checkout (core.autocrlf=true) converts this fixture's line ending to CRLF, breaking test_base64_file_input's fixed-digest assertion for any Windows contributor running the suite from a fresh clone.
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.
Changes being requested
Add a
.gitattributesmarkingtests/sample_file.txt -text.A default Windows checkout (
core.autocrlf=true, the setting Git for Windows recommends) converts that fixture to CRLF because nothing tells Git it is a fixed byte fixture.test_base64_file_inputbase64-encodes the file and compares against a fixed LF-based digest, so it fails out of the box on a fresh Windows clone:With the attribute,
git ls-files --eol tests/sample_file.txtshowsi/lf w/lf attr/-textandpytest tests/test_transform.py -k base64_file_inputgoes from 2 failed to 2 passed on the same clone; the rest oftests/test_transform.py(60 tests) stays green. The fixture's bytes in the repository are unchanged.Additional context & links
The file is not generated code, so nothing in the SDK regeneration touches it. Same shape as other repos' fixture handling for byte-exact test inputs.