1use std::panic;
2
3mod panik;
4
5pub fn install() {
6 let previous_hook = panic::take_hook();
7
8 panic::set_hook(Box::new(move |info| {
9 previous_hook(info);
10 eprintln!("{}", panik::PANIK);
11 }));
12}
13
14
15#[test]
16fn panic() {
17 install();
18
19 panic!("AAA")
20}