Skip to content

Path::starts_with and ends_with should be case-insensitive on Windows #66260

Closed
@zuobaoquan

Description

@zuobaoquan
#[test]
fn test_path_starts_with() {
    let path = PathBuf::from(r"C:\A\b");
    assert!(path.starts_with(r"C:\a"));
}

#[test]
fn test_path_ends_with() {
    let path = PathBuf::from(r"C:\a\b");
    assert!(path.ends_with("B"));
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsC-enhancementCategory: An issue proposing an enhancement or a PR with one.O-windowsOperating system: WindowsT-libsRelevant to the library team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions