Add a test for `""` and `"."`.
}
fn create_dir_all(&self, path: &Path) -> io::Result<()> {
+ if path == Path::new("") {
+ return Ok(())
+ }
+
match self.inner.mkdir(path) {
Ok(()) => return Ok(()),
Err(ref e) if e.kind() == io::ErrorKind::NotFound => {}
check!(fs::create_dir_all(&Path::new("/")));
}
+ #[test]
+ fn recursive_mkdir_dot() {
+ check!(fs::create_dir_all(&Path::new(".")));
+ }
+
+ #[test]
+ fn recursive_mkdir_empty() {
+ check!(fs::create_dir_all(&Path::new("")));
+ }
+
#[test]
fn recursive_rmdir() {
let tmpdir = tmpdir();