Skip to content

Commit f50fb3f

Browse files
committed
add a case for Asia/Kathmandu
Signed-off-by: Ruihang Xia <waynestxia@gmail.com>
1 parent 6b9de5b commit f50fb3f

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

datafusion/functions/src/datetime/date_trunc.rs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -946,6 +946,21 @@ mod tests {
946946
"2018-11-04T02:00:00-02",
947947
],
948948
),
949+
(
950+
vec![
951+
"2024-10-26T23:30:00Z",
952+
"2024-10-27T00:30:00Z",
953+
"2024-10-27T01:30:00Z",
954+
"2024-10-27T02:30:00Z",
955+
],
956+
Some("Asia/Kathmandu".into()), // UTC+5:45
957+
vec![
958+
"2024-10-27T05:00:00+05:45",
959+
"2024-10-27T06:00:00+05:45",
960+
"2024-10-27T07:00:00+05:45",
961+
"2024-10-27T08:00:00+05:45",
962+
],
963+
),
949964
];
950965

951966
cases.iter().for_each(|(original, tz_opt, expected)| {

0 commit comments

Comments
 (0)