Skip to content

Commit d03623e

Browse files
committed
fixup! date: add support for negative date arithmetic with - operator
1 parent 0fa1d68 commit d03623e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/uu/date/src/date.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1663,7 +1663,9 @@ mod tests {
16631663

16641664
// Test negative arithmetic patterns
16651665
assert!(try_parse_gnu_compatible_arithmetic("1970-12-31 - 1 year").is_some());
1666-
assert!(try_parse_gnu_compatible_arithmetic("1970-12-31T23:59:59+00:00 - 1 year").is_some());
1666+
assert!(
1667+
try_parse_gnu_compatible_arithmetic("1970-12-31T23:59:59+00:00 - 1 year").is_some()
1668+
);
16671669
assert!(try_parse_gnu_compatible_arithmetic("1999-01-01 2 years ago").is_some());
16681670
}
16691671
}

0 commit comments

Comments
 (0)