#NEWLINE# def test_save_with_tz_date( data_client ) : #NEWLINE# #INDENT# tzinfo = timezone ( 'Europe/Prague' ) #NEWLINE# first_commit = Commit . get ( id = '3ca6e1e73a071a705b4babd2f581c91a2a3e5037' , parent = 'elasticsearch-dsl-py' ) #NEWLINE# first_commit . committed_date = tzinfo . localize ( datetime ( 2014 , 5 , 2 , 13 , 47 , 19 , 123456 ) ) #NEWLINE# first_commit . save ( ) #NEWLINE# first_commit = Commit . get ( id = '3ca6e1e73a071a705b4babd2f581c91a2a3e5037' , parent = 'elasticsearch-dsl-py' ) #NEWLINE# assert ( tzinfo . localize ( datetime ( 2014 , 5 , 2 , 13 , 47 , 19 , 123456 ) ) == first_commit . committed_date )