summaryrefslogtreecommitdiff
path: root/tests/util
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2024-06-06 08:37:13 -0400
committerGitHub <noreply@github.com>2024-06-06 08:37:13 -0400
commite5b2c5ebb89b962faec2937b3befa01ced90c579 (patch)
treee7e06f1391ddb71da97b5c6910ea2eeab0fe20ea /tests/util
parent4d531bf229069f28b96c53c7c0f30f068b410382 (diff)
chore: support `-- --nocapture` in the spec tests (#24113)
Diffstat (limited to 'tests/util')
-rw-r--r--tests/util/server/src/builders.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/util/server/src/builders.rs b/tests/util/server/src/builders.rs
index bd2d02f3f..58563bd03 100644
--- a/tests/util/server/src/builders.rs
+++ b/tests/util/server/src/builders.rs
@@ -387,7 +387,7 @@ pub struct TestCommandBuilder {
args_text: String,
args_vec: Vec<String>,
split_output: bool,
- debug_output: bool,
+ show_output: bool,
}
impl TestCommandBuilder {
@@ -407,7 +407,7 @@ impl TestCommandBuilder {
command_name: "deno".to_string(),
args_text: "".to_string(),
args_vec: Default::default(),
- debug_output: false,
+ show_output: false,
}
}
@@ -489,8 +489,8 @@ impl TestCommandBuilder {
/// Not deprecated, this is just here so you don't accidentally
/// commit code with this enabled.
#[deprecated]
- pub fn debug_output(mut self) -> Self {
- self.debug_output = true;
+ pub fn show_output(mut self) -> Self {
+ self.show_output = true;
self
}
@@ -662,15 +662,15 @@ impl TestCommandBuilder {
let (stderr_reader, stderr_writer) = pipe().unwrap();
command.stdout(stdout_writer);
command.stderr(stderr_writer);
- let debug_output = self.debug_output;
+ let show_output = self.show_output;
(
None,
Some((
std::thread::spawn(move || {
- read_pipe_to_string(stdout_reader, debug_output)
+ read_pipe_to_string(stdout_reader, show_output)
}),
std::thread::spawn(move || {
- read_pipe_to_string(stderr_reader, debug_output)
+ read_pipe_to_string(stderr_reader, show_output)
}),
)),
)
@@ -695,7 +695,7 @@ impl TestCommandBuilder {
drop(command);
let combined = combined_reader.map(|pipe| {
- sanitize_output(read_pipe_to_string(pipe, self.debug_output), &args)
+ sanitize_output(read_pipe_to_string(pipe, self.show_output), &args)
});
let status = process.wait().unwrap();