Skip to content

Commit 724528d

Browse files
Devel08cakebaker
authored andcommitted
add test for issue 11937
1 parent 3166b06 commit 724528d

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

tests/by-util/test_numfmt.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1549,3 +1549,13 @@ fn test_si_format_precision_no_cap() {
15491549
.succeeds()
15501550
.stdout_is("1.23457M\n");
15511551
}
1552+
1553+
// https://github.com/uutils/coreutils/issues/11937
1554+
// numfmt: --format width accounting diverges from GNU for multi-byte --suffix
1555+
#[test]
1556+
fn test_multibyte_suffix_issue11937() {
1557+
new_ucmd!()
1558+
.args(&["--suffix=€", "--format=%10.2f", "692"])
1559+
.succeeds()
1560+
.stdout_is(" 692.00€\n");
1561+
}

0 commit comments

Comments
 (0)