()
| 533 | |
| 534 | #[test] |
| 535 | fn test_stats_reset() { |
| 536 | let monitor = MemoryMonitor::new(); |
| 537 | |
| 538 | monitor.record_buffer_allocation(1024); |
| 539 | monitor.record_message_allocation(2048); |
| 540 | |
| 541 | let stats_before = monitor.get_stats(); |
| 542 | assert!(stats_before.total_bytes() > 0); |
| 543 | |
| 544 | monitor.reset_stats(); |
| 545 | |
| 546 | let stats_after = monitor.get_stats(); |
| 547 | assert_eq!(stats_after.total_bytes(), 0); |
| 548 | } |
| 549 | |
| 550 | #[test] |
| 551 | fn test_global_memory_monitor() { |
nothing calls this directly
no test coverage detected