()
| 244 | |
| 245 | #[test] |
| 246 | fn force_flush_over_threshold() { |
| 247 | let config = CheckpointConfig { |
| 248 | force_flush_threshold: 50, |
| 249 | tick_interval: Duration::from_millis(0), |
| 250 | ..Default::default() |
| 251 | }; |
| 252 | let mut coord = CheckpointCoordinator::new(config); |
| 253 | coord.register_engine("sparse"); |
| 254 | coord.mark_dirty("sparse", 100); // Over threshold. |
| 255 | |
| 256 | let plan = coord.tick(); |
| 257 | let sparse_flush = plan.iter().find(|(e, _)| e == "sparse").unwrap().1; |
| 258 | assert_eq!(sparse_flush, 100); // Force full flush. |
| 259 | } |
| 260 | |
| 261 | #[test] |
| 262 | fn clean_after_all_flushed() { |
nothing calls this directly
no test coverage detected