diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2024-02-29 10:12:43 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2024-02-29 10:12:43 -0500 |
commit | e6d80d04d6928c452b48eae717373bf6a943e355 (patch) | |
tree | b0db89b106d8f0e5aa2e768fc4127701c16f2e1b /tests | |
parent | a9f3cde30426b546ba6e3172e1a7951213a72049 (diff) | |
download | bfs-e6d80d04d6928c452b48eae717373bf6a943e355.tar.xz |
tests: Add more datetime parsing integration tests
Diffstat (limited to 'tests')
-rw-r--r-- | tests/common/newermt.sh | 4 | ||||
-rw-r--r-- | tests/xtime.c | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/tests/common/newermt.sh b/tests/common/newermt.sh index 3c5be68..e816b29 100644 --- a/tests/common/newermt.sh +++ b/tests/common/newermt.sh @@ -1 +1,3 @@ -bfs_diff times -newermt 1991-12-14T00:01 +bfs_diff times -newermt 1991-12-14T00:01 \ + -newermt "1991-12-14 01:01+01:00" \ + -newermt "19911213 20:31:00-0330" diff --git a/tests/xtime.c b/tests/xtime.c index c2ee8f3..4a7d55c 100644 --- a/tests/xtime.c +++ b/tests/xtime.c @@ -94,10 +94,10 @@ static bool check_xgetdate(void) { & compare_xgetdate("1991-12-14T10:11Z", 0, 692705460) & compare_xgetdate("1991-12-14T10:11:12Z", 0, 692705472) & compare_xgetdate("1991-12-14T10:11:12?", EINVAL, 0) - & compare_xgetdate("1991-12-14T02-08", 0, 692704800) + & compare_xgetdate("1991-12-14T03-07", 0, 692704800) & compare_xgetdate("1991-12-14T06:41-03:30", 0, 692705460) - & compare_xgetdate("1991-12-14T02:11:12-08:00", 0, 692705472) - & compare_xgetdate("19911214 021112-0800", 0, 692705472); + & compare_xgetdate("1991-12-14T03:11:12-07:00", 0, 692705472) + & compare_xgetdate("19911214 031112-0700", 0, 692705472); } /** xmktime() tests. */ |