msvc-kit 0.2.16

A portable MSVC Build Tools installer and manager for Rust development
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use std::process::Command;

#[test]
fn cli_reads_install_directory_from_environment() {
    let dir = tempfile::tempdir().unwrap();
    let target = dir.path().join("kit with spaces");
    let output = Command::new(env!("CARGO_BIN_EXE_msvc-kit"))
        .arg("config")
        .env("MSVC_KIT_DIR", &target)
        .output()
        .unwrap();
    assert!(output.status.success());
    assert!(String::from_utf8_lossy(&output.stdout).contains(&target.display().to_string()));
    assert!(
        !target.exists(),
        "reading configuration must not install anything"
    );
}