1 2 3 4 5 6 7 8 9 10 11 12
use camber::runtime; #[test] fn runtime_runs_closure_and_returns_unit() { runtime::run(|| {}).unwrap(); } #[test] fn runtime_runs_closure_and_returns_value() { let result = runtime::run(|| 42).unwrap(); assert_eq!(result, 42); }