MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_format_duration_ms

Function test_format_duration_ms

atomic-core/src/change/attestation.rs:1723–1732  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1721
1722 #[test]
1723 fn test_format_duration_ms() {
1724 assert_eq!(format_duration_ms(500), "500ms");
1725 assert_eq!(format_duration_ms(1_000), "1s");
1726 assert_eq!(format_duration_ms(45_000), "45s");
1727 assert_eq!(format_duration_ms(60_000), "1m");
1728 assert_eq!(format_duration_ms(172_000), "2m 52s");
1729 assert_eq!(format_duration_ms(2_354_000), "39m 14s");
1730 assert_eq!(format_duration_ms(3_600_000), "1h 0m");
1731 assert_eq!(format_duration_ms(3_661_000), "1h 1m 1s");
1732 }
1733
1734 // CB-12A fix-session regressions (review ATOM::aaron::8 R1/R6).
1735

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected