MCPcopy Create free account
hub / github.com/Wulf/tsync / test_parse_number

Function test_parse_number

src/utils.rs:303–308  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

301
302#[test]
303fn test_parse_number() {
304 assert_eq!(parse_number_autoradix("2_3".into()), Some(23));
305 assert_eq!(parse_number_autoradix("0xf".into()), Some(15));
306 assert_eq!(parse_number_autoradix("0b11".into()), Some(3));
307 assert_eq!(parse_number_autoradix("0o1_1".into()), Some(0o1_1));
308}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected