30 lines · 732 B · Rust
RawDownload
mod bytes {    use bstr::ByteSlice;    use git_features::path;     #[test]    fn assure_unix_separators() {        assert_eq!(            path::convert::to_unix_separators(b"no-backslash".as_ref()).as_bstr(),            "no-backslash"        );         assert_eq!(            path::convert::to_unix_separators(b"\\a\\b\\\\".as_ref()).as_bstr(),            "/a/b//"        );    }     #[test]    fn assure_windows_separators() {        assert_eq!(            path::convert::to_windows_separators(b"no-backslash".as_ref()).as_bstr(),            "no-backslash"        );         assert_eq!(            path::convert::to_windows_separators(b"/a/b//".as_ref()).as_bstr(),            "\\a\\b\\\\"        );    }}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t