1 use common::{args, check};
2 use libtest_mimic::{Trial, Conclusion};
3 
4 #[macro_use]
5 mod common;
6 
7 
tests() -> Vec<Trial>8 fn tests() -> Vec<Trial> {
9     vec![
10         Trial::test("passes", || Ok(())),
11         Trial::test("panics", || panic!("uh oh")),
12     ]
13 }
14 
15 #[test]
normal()16 fn normal() {
17     check(args([]), tests, 2,
18         Conclusion {
19             num_filtered_out: 0,
20             num_passed: 1,
21             num_failed: 1,
22             num_ignored: 0,
23             num_measured: 0,
24         },
25         "
26             test passes ... ok
27             test panics ... FAILED
28 
29             failures:
30 
31             ---- panics ----
32             test panicked: uh oh
33 
34 
35             failures:
36                 panics
37         "
38     );
39 }
40