File tree 1 file changed +7
-3
lines changed
pandas/tests/scalar/timestamp
1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -751,7 +751,7 @@ def test_asm8(self):
751
751
752
752
def test_class_ops_pytz (self ):
753
753
def compare (x , y ):
754
- assert int (Timestamp (x ).value / 1e9 ) == int ( Timestamp (y ).value / 1e9 )
754
+ assert int (( Timestamp (x ).value - Timestamp (y ).value ) / 1e9 ) == 0
755
755
756
756
compare (Timestamp .now (), datetime .now ())
757
757
compare (Timestamp .now ("UTC" ), datetime .now (timezone ("UTC" )))
@@ -775,8 +775,12 @@ def compare(x, y):
775
775
776
776
def test_class_ops_dateutil (self ):
777
777
def compare (x , y ):
778
- assert int (np .round (Timestamp (x ).value / 1e9 )) == int (
779
- np .round (Timestamp (y ).value / 1e9 )
778
+ assert (
779
+ int (
780
+ np .round (Timestamp (x ).value / 1e9 )
781
+ - np .round (Timestamp (y ).value / 1e9 )
782
+ )
783
+ == 0
780
784
)
781
785
782
786
compare (Timestamp .now (), datetime .now ())
You can’t perform that action at this time.
0 commit comments