Skip to content

Commit

Permalink
Merge pull request #806 from fluidvanadium/error_message_directory
Browse files Browse the repository at this point in the history
upgraded error message
  • Loading branch information
AloeareV authored Feb 6, 2024
2 parents 9e024d9 + d28d8ac commit 1a0fb7b
Showing 1 changed file with 22 additions and 5 deletions.
27 changes: 22 additions & 5 deletions zingo-testutils/src/regtest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,12 +126,21 @@ pub fn launch_lightwalletd(
]
});
let prepped_args = args.iter().map(|x| x.to_string()).collect::<Vec<_>>();
let mut lightwalletd_child = std::process::Command::new(bin)
let mut lightwalletd_child = std::process::Command::new(bin.clone())
.args(prepped_args)
.stdout(std::process::Stdio::piped())
.stderr(std::process::Stdio::piped())
.spawn()
.expect("failed to start lightwalletd. It's possible the lightwalletd binary is not in the $G/test_binaries/bins/. see docs/integration-tests.txt");
.unwrap_or_else(|_| {
panic!(
"{}",
format!(
"failed to start lightwalletd at {}. see docs/integration-tests.txt",
bin.display()
)
.to_owned()
)
});

if let Some(mut lwd_stdout_data) = lightwalletd_child.stdout.take() {
std::thread::spawn(move || {
Expand Down Expand Up @@ -326,9 +335,17 @@ impl RegtestManager {
log::info!("{:?}", &command.get_envs());
log::info!("{:?}", &command.get_program());

let child = command
.spawn()
.expect("COULD NOT START ZCASHD does it exist? see $G/docs/ZINGOCLI-REGTEST.md");
let child = command.spawn().unwrap_or_else(|_| {
panic!(
"{}",
format!(
"failed to start zcashd at {}. see docs/integration-tests.txt",
self.bin_dir.clone().display()
)
.to_owned()
)
});

log::debug!("zcashd is starting in regtest mode, please standby...");

(
Expand Down

0 comments on commit 1a0fb7b

Please sign in to comment.