diff --git a/src/app.rs b/src/app.rs index 9850b69..86bdf47 100644 --- a/src/app.rs +++ b/src/app.rs @@ -318,7 +318,7 @@ pub fn validate_time_format(formatter: &str) -> Result<(), String> { | Some('W') | Some('w') | Some('Y') | Some('y') => (), Some(c) => return Err(format!("invalid format specifier: %{}{}", n, c)), None => return Err("missing format specifier".to_owned()), - } + }, Some('A') | Some('a') | Some('B') | Some('b') | Some('C') | Some('c') | Some('D') | Some('d') | Some('e') | Some('F') | Some('f') | Some('G') | Some('g') | Some('H') | Some('h') | Some('I') | Some('j') | Some('k') diff --git a/tests/integration.rs b/tests/integration.rs index b3f8073..574768a 100644 --- a/tests/integration.rs +++ b/tests/integration.rs @@ -606,7 +606,11 @@ fn test_date_custom_format_supports_nanos_with_length() { .arg("--ignore-config") .arg(dir.path()) .assert() - .stdout(predicate::str::is_match("testDateFormat\\.[0-9]{3}").unwrap().count(2)); + .stdout( + predicate::str::is_match("testDateFormat\\.[0-9]{3}") + .unwrap() + .count(2), + ); } #[test] @@ -622,5 +626,9 @@ fn test_date_custom_format_supports_padding() { .arg("--ignore-config") .arg(dir.path()) .assert() - .stdout(predicate::str::is_match("testDateFormat[\\s0-9]{2}").unwrap().count(2)); + .stdout( + predicate::str::is_match("testDateFormat[\\s0-9]{2}") + .unwrap() + .count(2), + ); }