MCPcopy Index your code
hub / github.com/assert-rs/assert_cmd / stdout_impl

Method stdout_impl

src/assert.rs:400–410  ·  view source on GitHub ↗
(self, pred: &dyn predicates_core::Predicate<[u8]>)

Source from the content-addressed store, hash-verified

398 }
399
400 fn stdout_impl(self, pred: &dyn predicates_core::Predicate<[u8]>) -> AssertResult {
401 {
402 let actual = &self.output.stdout;
403 if let Some(case) = pred.find_case(false, actual) {
404 return Err(self.into_error(AssertReason::UnexpectedStdout {
405 case_tree: CaseTree(case.tree()),
406 }));
407 }
408 }
409 Ok(self)
410 }
411
412 /// Ensure the command wrote the expected data to `stderr`.
413 ///

Callers 1

try_stdoutMethod · 0.80

Calls 3

CaseTreeClass · 0.85
find_caseMethod · 0.80
into_errorMethod · 0.80

Tested by

no test coverage detected