Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Improve test daemon logging #68

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions tests/helpers/daemon.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ impl MpdConfig {
format!(
r#"
db_file "{db_file}"
log_file "/dev/null"
music_directory "{music_directory}"
playlist_directory "{playlist_directory}"
sticker_file "{sticker_file}"
Expand Down Expand Up @@ -76,8 +75,7 @@ impl Drop for Daemon {
if let Some(ref mut stderr) = self.process.stderr {
let mut output = String::new();
stderr.read_to_string(&mut output).expect("Could not collect output from mpd.");
println! {"Output from mpd:"}
println! {"{}", output};
println!("Output from mpd:\n{output}");
}
}
}
Expand All @@ -101,6 +99,8 @@ impl Daemon {

let process = Command::new("mpd")
.arg("--no-daemon")
.arg("--verbose")
.arg("--stderr")
.arg(&config.config_path)
.stdin(Stdio::null())
.stdout(Stdio::null())
Expand Down
Loading