Skip to content

additional edge cases tests for path.rs 🧪 #141105

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

GrantBirki
Copy link

@GrantBirki GrantBirki commented May 16, 2025

This pull request adds a few new edge case tests to the std::path module. The new tests cover scenarios such as paths with only separators, non-ASCII and Unicode characters, embedded new lines, etc. Each new test is documented with some helpful in-line comments as well.

@rustbot
Copy link
Collaborator

rustbot commented May 16, 2025

r? @jhpratt

rustbot has assigned @jhpratt.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels May 16, 2025
@rust-log-analyzer

This comment has been minimized.

@GrantBirki
Copy link
Author

It appears that mingw-check-tidy failed, but I am not sure how to correct it. Perhaps its a linter of some sort?

@ChaiTRex
Copy link
Contributor

It appears that mingw-check-tidy failed, but I am not sure how to correct it. Perhaps its a linter of some sort?

mingw-check also failed. Click on CI / PR - mingw-check (pull_request) and see the compiler errors toward the bottom.

@ChaiTRex
Copy link
Contributor

It looks as if OsStrExt and OsStringExt have different methods on Windows than other platforms.

@workingjubilee
Copy link
Member

Yes, please fix the tests to only use functions from OsStr and OsString OR cfg the tests.

@rust-log-analyzer

This comment has been minimized.

@GrantBirki
Copy link
Author

@ChrisDenton I went ahead and removed a few of the tests that I added which feel rather superfluous now after reading your comments. This slims down the PR to really just be three new unit tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants