(root: &Path, args: &[&str])
| 2166 | } |
| 2167 | |
| 2168 | fn git_ok(root: &Path, args: &[&str]) { |
| 2169 | let output = ProcessCommand::new("git") |
| 2170 | .arg("-C") |
| 2171 | .arg(root) |
| 2172 | .args(args) |
| 2173 | .output() |
| 2174 | .unwrap(); |
| 2175 | assert!( |
| 2176 | output.status.success(), |
| 2177 | "git {args:?} failed: {}", |
| 2178 | String::from_utf8_lossy(&output.stderr) |
| 2179 | ); |
| 2180 | } |
| 2181 | |
| 2182 | fn init_git(root: &Path) { |
| 2183 | git_ok(root, &["init", "-q"]); |
no test coverage detected