File tree Expand file tree Collapse file tree 2 files changed +11
-2
lines changed
Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ pub fn timezone_short_name(date: &DateTimeType) -> String {
5151 tz_id[ tz_id. find ( '/' ) . map_or ( 0 , |v| v + 1 ) ..] . to_string ( )
5252}
5353
54- static PREFIXES : [ & str ; 14 ] = [
54+ static PREFIXES : [ & str ; 18 ] = [
5555 "Africa" ,
5656 "America" ,
5757 "Asia" ,
@@ -66,6 +66,10 @@ static PREFIXES: [&str; 14] = [
6666 "Mexico" ,
6767 "Pacific" ,
6868 "US" ,
69+ "America/Argentina" ,
70+ "America/Indiana" ,
71+ "America/Kentucky" ,
72+ "America/North_Dakota" ,
6973] ;
7074
7175fn find_timezone ( name : & str ) -> Result < Tz , String > {
Original file line number Diff line number Diff line change @@ -61,10 +61,15 @@ fn test_zinc_datetime_utc_decode_millis() {
6161}
6262
6363#[ test]
64- fn test_zinc_datetime_utc_decode_tz ( ) {
64+ fn test_zinc_datetime_utc_decode_tz_london ( ) {
6565 assert ! ( from_str( "2020-02-10T16:00:00.0Z London" ) . is_ok( ) ) ;
6666}
6767
68+ #[ test]
69+ fn test_zinc_datetime_utc_decode_tz_la_rioja ( ) {
70+ assert ! ( from_str( "2020-02-10T16:00:00.0+02:00 La_Rioja" ) . is_ok( ) ) ;
71+ }
72+
6873#[ test]
6974fn test_zinc_datetime_utc_decode_bad ( ) {
7075 assert ! ( from_str( "1996-12-19T16:39:57K" ) . is_err( ) ) ;
You can’t perform that action at this time.
0 commit comments