()
| 603 | |
| 604 | #[test] |
| 605 | fn finish_with() { |
| 606 | let mut sink = ReportSink::new(); |
| 607 | |
| 608 | sink.append(Report::new(TestError(0))); |
| 609 | sink.append(Report::new(TestError(1))); |
| 610 | |
| 611 | let report = sink.finish_with(|| 8).expect_err("should have failed"); |
| 612 | |
| 613 | let contexts: BTreeSet<_> = report.current_contexts().collect(); |
| 614 | assert_eq!(contexts.len(), 2); |
| 615 | assert!(contexts.contains(&TestError(0))); |
| 616 | assert!(contexts.contains(&TestError(1))); |
| 617 | } |
| 618 | |
| 619 | #[test] |
| 620 | fn finish_with_ok() { |
nothing calls this directly
no test coverage detected