Skip to content

Commit 7f0a909

Browse files
committed
Use timestamp_opt() instead of timestamp() in test
1 parent ff0f99b commit 7f0a909

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/parse_datetime.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ mod tests {
255255
];
256256

257257
for offset in offsets {
258-
let time = Utc.timestamp(offset, 0);
258+
let time = Utc.timestamp_opt(offset, 0).unwrap();
259259
let dt = from_str(format!("@{}", offset));
260260
assert_eq!(dt.unwrap(), time);
261261
}

0 commit comments

Comments
 (0)