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

test_date: Add test for quarter

This was fixed upstream in #7333, but it's a good idea to have a
test here as well, especially as we're considering switching
datetime library.
This commit is contained in:
Nicolas Boichat 2025-04-28 16:39:18 +08:00
parent 25e4410c3b
commit 19e08d5c11

View file

@ -169,6 +169,14 @@ fn test_date_format_y() {
scene.ucmd().arg("+%y").succeeds().stdout_matches(&re); scene.ucmd().arg("+%y").succeeds().stdout_matches(&re);
} }
#[test]
fn test_date_format_q() {
let scene = TestScenario::new(util_name!());
let re = Regex::new(r"^[1-4]\n$").unwrap();
scene.ucmd().arg("+%q").succeeds().stdout_matches(&re);
}
#[test] #[test]
fn test_date_format_m() { fn test_date_format_m() {
let scene = TestScenario::new(util_name!()); let scene = TestScenario::new(util_name!());