1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-27 11:07:44 +00:00

test: printf: Add a test for scientific printing of negative number

This was broken before the last few commits.
This commit is contained in:
Nicolas Boichat 2025-03-11 11:50:33 +01:00
parent 92a291b71d
commit 0c0d119413

View file

@ -380,6 +380,14 @@ fn sub_num_dec_trunc() {
.stdout_only("pi is ~ 3.14159");
}
#[test]
fn sub_num_sci_negative() {
new_ucmd!()
.args(&["-1234 is %e", "-1234"])
.succeeds()
.stdout_only("-1234 is -1.234000e+03");
}
#[cfg_attr(not(feature = "test_unimplemented"), ignore)]
#[test]
fn sub_num_hex_float_lower() {