Capitalize "UTC" when pretty-printing

This commit is contained in:
Nathan Fisher 2024-01-30 00:24:56 -05:00
parent 3594cfafdf
commit c0def257fb
2 changed files with 2 additions and 2 deletions

View File

@ -283,7 +283,7 @@ mod tests {
#[test] #[test]
fn display() { fn display() {
let mut dt = DateTime::from_timestamp(1706571482); let mut dt = DateTime::from_timestamp(1706571482);
assert_eq!(dt.display(), "Mon Jan 29 23:38:02 Utc 2024"); assert_eq!(dt.display(), "Mon Jan 29 23:38:02 UTC 2024");
dt.zone = TimeZone::Offset { dt.zone = TimeZone::Offset {
sign: crate::zone::Sign::Positive, sign: crate::zone::Sign::Positive,
hours: 4, hours: 4,

View File

@ -97,7 +97,7 @@ impl TimeZone {
pub fn display(&self) -> String { pub fn display(&self) -> String {
match self { match self {
Self::Utc => "Utc".into(), Self::Utc => "UTC".into(),
_ => format!("{self}"), _ => format!("{self}"),
} }
} }