tests/mkdir: check for multiple --parent arguments

This commit is contained in:
Daringcuteseal 2024-10-31 05:06:21 +07:00
parent 41f52f3402
commit 8cecebc050
No known key found for this signature in database
GPG key ID: 173F4A541C0E39D7

View file

@ -61,9 +61,21 @@ fn test_mkdir_parent() {
let test_dir = "parent_dir/child_dir";
scene.ucmd().arg("-p").arg(test_dir).succeeds();
scene.ucmd().arg("-p").arg(test_dir).succeeds();
scene.ucmd().arg("-p").arg("-p").arg(test_dir).succeeds();
scene.ucmd().arg("--parent").arg(test_dir).succeeds();
scene
.ucmd()
.arg("--parent")
.arg("--parent")
.arg(test_dir)
.succeeds();
scene.ucmd().arg("--parents").arg(test_dir).succeeds();
scene
.ucmd()
.arg("--parents")
.arg("--parents")
.arg(test_dir)
.succeeds();
}
#[test]