()
| 461 | |
| 462 | #[test] |
| 463 | fn hook_for_context() { |
| 464 | let _guard = prepare(false); |
| 465 | |
| 466 | let report = create_report().attach_opaque(2_u32); |
| 467 | |
| 468 | Report::install_debug_hook::<RootError>(|_, _| { |
| 469 | // This should not be displayed as `RootError` is only used as `Context`, never as |
| 470 | // attachment. |
| 471 | unreachable!("A context should never be used as hook"); |
| 472 | }); |
| 473 | |
| 474 | assert_snapshot!(format!("{report:?}")); |
| 475 | } |
| 476 | |
| 477 | #[test] |
| 478 | fn hook_multiple() { |
nothing calls this directly
no test coverage detected