MCPcopy Create free account
hub / github.com/bendudson/EuraliOS / path_has_root

Function path_has_root

euralios_std/src/path.rs:989–997  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

987
988 #[test_case]
989 fn path_has_root() {
990 // Paths with root directory
991 assert!(Path::new("/etc/passwd").has_root());
992 assert!(Path::new("/").has_root());
993
994 // Some paths without root
995 assert!(!Path::new("./etc/passwd").has_root());
996 assert!(!Path::new(".").has_root());
997 }
998
999 #[test_case]
1000 fn path_components() {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected