MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_format_int_sep

Function test_format_int_sep

crates/common/src/format.rs:1529–1536  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1527
1528 #[test]
1529 fn test_format_int_sep() {
1530 let spec = FormatSpec::parse(",").expect("");
1531 assert_eq!(spec.grouping_option, Some(FormatGrouping::Comma));
1532 assert_eq!(
1533 spec.format_int(&BigInt::from_str("1234567890123456789012345678").unwrap()),
1534 Ok("1,234,567,890,123,456,789,012,345,678".to_owned())
1535 );
1536 }
1537
1538 #[test]
1539 fn test_format_int_width_and_grouping() {

Callers

nothing calls this directly

Calls 1

parseFunction · 0.50

Tested by

no test coverage detected