From a0ea5cfaa0e890ad79ec639bcbdb816baff59060 Mon Sep 17 00:00:00 2001 From: Andrey Kutejko Date: Sat, 13 Jan 2024 16:50:45 +0100 Subject: [PATCH] Update chrono and fix doc-tests Chrono changed day formatting in 0.4.31 https://github.com/chronotope/chrono/pull/1272 --- Cargo.toml | 2 +- src/channel.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 8c1f329747..757d3a6040 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -25,7 +25,7 @@ atom = ["atom_syndication"] quick-xml = { version = "0.30", features = ["encoding"] } derive_builder = { version = "0.12", optional = true } never = { version = "0.1", optional = true } -chrono = { version = "0.4", optional = true, default-features = false, features = ["alloc"] } +chrono = { version = "0.4.31", optional = true, default-features = false, features = ["alloc"] } url = { version = "2.1", optional = true } mime = { version = "0.3", optional = true } serde = { version = "1.0", optional = true, features = ["derive"] } diff --git a/src/channel.rs b/src/channel.rs index f58b1e152b..684cd43cbe 100644 --- a/src/channel.rs +++ b/src/channel.rs @@ -369,7 +369,7 @@ impl Channel { /// /// let mut channel = Channel::default(); /// channel.set_pub_date(Utc.with_ymd_and_hms(2017, 1, 1, 12, 0, 0).unwrap().to_rfc2822()); - /// assert_eq!(channel.pub_date(), Some("Sun, 01 Jan 2017 12:00:00 +0000")); + /// assert_eq!(channel.pub_date(), Some("Sun, 1 Jan 2017 12:00:00 +0000")); /// # } /// ``` pub fn set_pub_date(&mut self, pub_date: V) @@ -415,7 +415,7 @@ impl Channel { /// /// let mut channel = Channel::default(); /// channel.set_last_build_date(Utc.with_ymd_and_hms(2017, 1, 1, 12, 0, 0).unwrap().to_rfc2822()); - /// assert_eq!(channel.last_build_date(), Some("Sun, 01 Jan 2017 12:00:00 +0000")); + /// assert_eq!(channel.last_build_date(), Some("Sun, 1 Jan 2017 12:00:00 +0000")); /// # } /// ``` pub fn set_last_build_date(&mut self, last_build_date: V)