fixed usages of deprecated chrono DateTime::from_utc (#10161)

This addresses the warnings generated from using DateTime::from_utc.
DateTime::from_utc was deprecated as of chrono 0.4.27

Co-authored-by: Jack Wright <jack.wright@disqo.com>
This commit is contained in:
Jack Wright
2023-08-30 15:04:19 -07:00
committed by GitHub
parent b943cbedff
commit fd4ba0443d
3 changed files with 11 additions and 9 deletions

View File

@ -3993,7 +3993,7 @@ mod tests {
#[test]
fn test_datetime() {
let string = Value::Date {
val: DateTime::from_utc(
val: DateTime::from_naive_utc_and_offset(
NaiveDateTime::from_timestamp_millis(-123456789).unwrap(),
FixedOffset::east_opt(0).unwrap(),
),
@ -4010,7 +4010,7 @@ mod tests {
#[test]
fn test_negative_year_datetime() {
let string = Value::Date {
val: DateTime::from_utc(
val: DateTime::from_naive_utc_and_offset(
NaiveDateTime::from_timestamp_millis(-72135596800000).unwrap(),
FixedOffset::east_opt(0).unwrap(),
),