summaryrefslogtreecommitdiffstats
path: root/tests/by-util
diff options
context:
space:
mode:
authorMengshengWu <mengshengwu@deepglint.com>2024-06-28 22:01:00 +0800
committerMengshengWu <mengshengwu@deepglint.com>2024-06-28 22:01:00 +0800
commite4ec60878187360370268e5e5c51f7b31dd47336 (patch)
tree054b72581aeb1030b3e353e9a2c391b62b289768 /tests/by-util
parent11e84764564f5601c9a483ff2d067b4228f78588 (diff)
date: fix date get timezone error while set utc time (#6495)
Diffstat (limited to 'tests/by-util')
-rw-r--r--tests/by-util/test_date.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/by-util/test_date.rs b/tests/by-util/test_date.rs
index 16a01c655..13c340b07 100644
--- a/tests/by-util/test_date.rs
+++ b/tests/by-util/test_date.rs
@@ -142,6 +142,16 @@ fn test_date_utc() {
}
#[test]
+fn test_date_utc_issue_6495() {
+ new_ucmd!()
+ .arg("-u")
+ .arg("-d")
+ .arg("@0")
+ .succeeds()
+ .stdout_is("Thu Jan 1 00:00:00 1970\n");
+}
+
+#[test]
fn test_date_format_y() {
let scene = TestScenario::new(util_name!());