39 lines
886 B
Rust
39 lines
886 B
Rust
use crate::test;
|
|
use crate::util::environment::Environment;
|
|
|
|
#[test]
|
|
fn rad_checkout() {
|
|
let mut environment = Environment::new();
|
|
let profile = environment.profile("alice");
|
|
let copy = tempfile::tempdir().unwrap();
|
|
|
|
environment.repository(&profile);
|
|
|
|
environment.test("rad-init", &profile).unwrap();
|
|
test(
|
|
"examples/rad-checkout.md",
|
|
copy.path(),
|
|
Some(&profile.home),
|
|
[],
|
|
)
|
|
.unwrap();
|
|
|
|
if cfg!(target_os = "linux") {
|
|
test(
|
|
"examples/rad-checkout-repo-config-linux.md",
|
|
copy.path(),
|
|
Some(&profile.home),
|
|
[],
|
|
)
|
|
.unwrap();
|
|
} else if cfg!(target_os = "macos") {
|
|
test(
|
|
"examples/rad-checkout-repo-config-macos.md",
|
|
copy.path(),
|
|
Some(&profile.home),
|
|
[],
|
|
)
|
|
.unwrap();
|
|
}
|
|
}
|