@@ -181,7 +181,7 @@ def assert_dict_equal(left, right, compare_keys: bool = True) -> None:
181
181
def assert_index_equal (
182
182
left : Index ,
183
183
right : Index ,
184
- exact : bool | Literal [ "equiv" ] = True ,
184
+ exact : bool | str = "equiv" ,
185
185
check_names : bool = True ,
186
186
check_exact : bool = True ,
187
187
check_categorical : bool = True ,
@@ -203,9 +203,6 @@ def assert_index_equal(
203
203
Whether to check the Index class, dtype and inferred_type
204
204
are identical. If 'equiv', then RangeIndex can be substituted for
205
205
Index with an int64 dtype as well.
206
-
207
- .. versionchanged:: 3.0
208
- The default changed from ``'equiv'`` to ``True``
209
206
check_names : bool, default True
210
207
Whether to check the names attribute.
211
208
check_exact : bool, default True
@@ -471,7 +468,6 @@ def assert_categorical_equal(
471
468
_check_isinstance (left , right , Categorical )
472
469
473
470
exact : bool | str
474
- # TODO: Can this be made strict?
475
471
if isinstance (left .categories , RangeIndex ) or isinstance (
476
472
right .categories , RangeIndex
477
473
):
@@ -817,7 +813,7 @@ def assert_series_equal(
817
813
left ,
818
814
right ,
819
815
check_dtype : bool | Literal ["equiv" ] = True ,
820
- check_index_type : bool | Literal ["equiv" ] = True ,
816
+ check_index_type : bool | Literal ["equiv" ] = "equiv" ,
821
817
check_series_type : bool = True ,
822
818
check_names : bool = True ,
823
819
check_exact : bool | lib .NoDefault = lib .no_default ,
@@ -847,9 +843,6 @@ def assert_series_equal(
847
843
check_index_type : bool or {'equiv'}, default 'equiv'
848
844
Whether to check the Index class, dtype and inferred_type
849
845
are identical.
850
-
851
- .. versionchanged:: 3.0
852
- The default changed from ``'equiv'`` to ``True``
853
846
check_series_type : bool, default True
854
847
Whether to check the Series class is identical.
855
848
check_names : bool, default True
@@ -1112,8 +1105,8 @@ def assert_frame_equal(
1112
1105
left ,
1113
1106
right ,
1114
1107
check_dtype : bool | Literal ["equiv" ] = True ,
1115
- check_index_type : bool | Literal ["equiv" ] = True ,
1116
- check_column_type : bool | Literal ["equiv" ] = True ,
1108
+ check_index_type : bool | Literal ["equiv" ] = "equiv" ,
1109
+ check_column_type : bool | Literal ["equiv" ] = "equiv" ,
1117
1110
check_frame_type : bool = True ,
1118
1111
check_names : bool = True ,
1119
1112
by_blocks : bool = False ,
@@ -1143,19 +1136,13 @@ def assert_frame_equal(
1143
1136
Second DataFrame to compare.
1144
1137
check_dtype : bool, default True
1145
1138
Whether to check the DataFrame dtype is identical.
1146
- check_index_type : bool or {'equiv'}, default True
1139
+ check_index_type : bool or {'equiv'}, default 'equiv'
1147
1140
Whether to check the Index class, dtype and inferred_type
1148
1141
are identical.
1149
-
1150
- .. versionchanged:: 3.0
1151
- The default changed from ``'equiv'`` to ``True``
1152
- check_column_type : bool or {'equiv'}, default True
1142
+ check_column_type : bool or {'equiv'}, default 'equiv'
1153
1143
Whether to check the columns class, dtype and inferred_type
1154
1144
are identical. Is passed as the ``exact`` argument of
1155
1145
:func:`assert_index_equal`.
1156
-
1157
- .. versionchanged:: 3.0
1158
- The default changed from ``'equiv'`` to ``True``
1159
1146
check_frame_type : bool, default True
1160
1147
Whether to check the DataFrame class is identical.
1161
1148
check_names : bool, default True
0 commit comments