Skip to content

Commit

Permalink
Do not add empty suites to the results, to reduce space
Browse files Browse the repository at this point in the history
  • Loading branch information
Razican committed Sep 2, 2020
1 parent 22762d2 commit c232210
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions tester/src/exec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ impl TestSuite {
total,
passed,
ignored,
suites: suites.into_boxed_slice(),
suites,
tests: tests.into_boxed_slice(),
}
}
Expand Down Expand Up @@ -139,7 +139,7 @@ impl Test {
});

let passed = res.unwrap_or_else(|_| {
eprintln!("last panic was on test {}", self.name);
eprintln!("last panic was on test \"{}\"", self.name);
false
});

Expand Down
3 changes: 2 additions & 1 deletion tester/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,8 @@ struct SuiteResult {
total: usize,
passed: usize,
ignored: usize,
suites: Box<[SuiteResult]>,
#[serde(skip_serializing_if = "Vec::is_empty")]
suites: Vec<SuiteResult>,
tests: Box<[TestResult]>,
}

Expand Down

0 comments on commit c232210

Please sign in to comment.