Skip to content

Commit 9e807b4

Browse files
committed
add tests
1 parent ecda3d3 commit 9e807b4

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/by-util/test_sleep.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
use rstest::rstest;
66

77
use uucore::display::Quotable;
8-
// spell-checker:ignore dont SIGBUS SIGSEGV sigsegv sigbus
8+
// spell-checker:ignore dont SIGBUS SIGSEGV sigsegv sigbus infd
99
use uutests::new_ucmd;
1010
use uutests::util::TestScenario;
1111
use uutests::util_name;
@@ -294,6 +294,8 @@ fn test_negative_interval() {
294294
#[case::frac_suffix("0x0.001h")]
295295
#[case::scientific("0x1.0p-3")]
296296
#[case::scientific_suffix("0x1.0p-4s")]
297+
#[case::inf("infd")]
298+
#[case::inf("iNfd")]
297299
fn test_valid_hex_duration(#[case] input: &str) {
298300
new_ucmd!().args(&["--", input]).succeeds().no_output();
299301
}
@@ -302,6 +304,9 @@ fn test_valid_hex_duration(#[case] input: &str) {
302304
#[case::negative("-0x1")]
303305
#[case::negative_suffix("-0x1s")]
304306
#[case::negative_frac_suffix("-0x0.1s")]
307+
#[case::wrong_capitalization("infD")]
308+
#[case::wrong_capitalization("INFD")]
309+
#[case::wrong_capitalization("iNfD")]
305310
fn test_invalid_hex_duration(#[case] input: &str) {
306311
new_ucmd!()
307312
.args(&["--", input])

0 commit comments

Comments
 (0)