glob-std.rs |
", false);
mk_file("bbb/specials/?", false);
}
mk_file("bbb/specials/[", false);
mk_file("bbb/specials/]", false);
mk_file("ccc", true);
mk_file("xyz", true);
mk_file("xyz/x", false);
mk_file("xyz/y", false);
mk_file("xyz/z", false);
mk_file("r", true);
mk_file("r/current_dir.md", false);
mk_file("r/one", true);
mk_file("r/one/a.md", false);
mk_file("r/one/another", true);
mk_file("r/one/another/a.md", false);
mk_file("r/one/another/deep", true);
mk_file("r/one/another/deep/spelunking.md", false);
mk_file("r/another", true);
mk_file("r/another/a.md", false);
mk_file("r/two", true);
mk_file("r/two/b.md", false);
mk_file("r/three", true);
mk_file("r/three/c.md", false);
// all recursive entities
assert_eq!(
glob_vec("r/**"),
vec!(
PathBuf::from("r/another"),
PathBuf::from("r/one"),
PathBuf::from("r/one/another"),
PathBuf::from("r/one/another/deep"),
PathBuf::from("r/three"),
PathBuf::from("r/two")
)
);
// collapse consecutive recursive patterns
assert_eq!(
glob_vec("r/* |
11556 |