mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-28 11:20:36 +00:00
22 lines
491 B
Rust
22 lines
491 B
Rust
use crate::prelude::*;
|
|
use cargo_test_support::file;
|
|
use cargo_test_support::paths;
|
|
use cargo_test_support::str;
|
|
use std::fs;
|
|
|
|
#[cargo_test]
|
|
fn case() {
|
|
let foo = &paths::root().join("foo.bar");
|
|
fs::create_dir_all(foo).unwrap();
|
|
|
|
snapbox::cmd::Command::cargo_ui()
|
|
.arg_line("init")
|
|
.current_dir(foo)
|
|
.assert()
|
|
.code(101)
|
|
.stdout_eq(str![""])
|
|
.stderr_eq(file!["stderr.term.svg"]);
|
|
|
|
assert!(!foo.join("Cargo.toml").is_file());
|
|
}
|