MCPcopy Create free account
hub / github.com/aws/clock-bound / clock_source_to_bytes

Function clock_source_to_bytes

clock-bound/src/daemon/selected_clock.rs:309–311  ·  view source on GitHub ↗
(#[case] source: ClockSource, #[case] expected: [u8; 4])

Source from the content-addressed store, hash-verified

307 #[case(ClockSource::Server(u32::from_be_bytes([192, 168, 1, 1])), [192, 168, 1, 1])]
308 #[case(ClockSource::Server(u32::from_be_bytes([169, 254, 169, 123])), [169, 254, 169, 123])]
309 fn clock_source_to_bytes(#[case] source: ClockSource, #[case] expected: [u8; 4]) {
310 assert_eq!(<[u8; 4]>::from(source), expected);
311 }
312
313 #[test]
314 fn selected_clock_source_display() {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected