@@ -5,7 +5,6 @@ from collections.abc import (
55)
66from contextlib import contextmanager
77from typing import (
8- Any ,
98 Literal ,
109 overload ,
1110)
@@ -36,29 +35,29 @@ from pandas._typing import (
3635def assert_almost_equal (
3736 left : T ,
3837 right : T ,
39- check_dtype : bool | Literal ["equiv" ] = ... ,
40- rtol : float = ... ,
41- atol : float = ... ,
38+ check_dtype : bool | Literal ["equiv" ] = "equiv" ,
39+ rtol : float = 1e-5 ,
40+ atol : float = 1e-8 ,
4241 ** kwargs ,
4342) -> None : ...
44- def assert_dict_equal (left : dict , right : dict , compare_keys : bool = ... ) -> None : ...
43+ def assert_dict_equal (left : dict , right : dict , compare_keys : bool = True ) -> None : ...
4544def assert_index_equal (
4645 left : Index ,
4746 right : Index ,
48- exact : bool | Literal ["equiv" ] = ... ,
49- check_names : bool = ... ,
50- check_exact : bool = ... ,
51- check_categorical : bool = ... ,
52- check_order : bool = ... ,
53- rtol : float = ... ,
54- atol : float = ... ,
55- obj : str = ... ,
47+ exact : bool | Literal ["equiv" ] = "equiv" ,
48+ check_names : bool = True ,
49+ check_exact : bool = True ,
50+ check_categorical : bool = True ,
51+ check_order : bool = True ,
52+ rtol : float = 1e-5 ,
53+ atol : float = 1e-8 ,
54+ obj : str = "Index" ,
5655) -> None : ...
5756def assert_class_equal (
58- left : T , right : T , exact : bool | Literal ["equiv" ] = ... , obj : str = ...
57+ left : T , right : T , exact : bool | Literal ["equiv" ] = True , obj : str = "Input"
5958) -> None : ...
6059def assert_attr_equal (
61- attr : str , left : object , right : object , obj : str = ...
60+ attr : str , left : object , right : object , obj : str = "Attributes"
6261) -> None : ...
6362def assert_is_valid_plot_return_object (
6463 objs : Series | np .ndarray | Artist | tuple | dict ,
@@ -67,44 +66,50 @@ def assert_is_sorted(seq: AnyArrayLike) -> None: ...
6766def assert_categorical_equal (
6867 left : Categorical ,
6968 right : Categorical ,
70- check_dtype : bool = ... ,
71- check_category_order : bool = ... ,
72- obj : str = ... ,
69+ check_dtype : bool = True ,
70+ check_category_order : bool = True ,
71+ obj : str = "Categorical" ,
7372) -> None : ...
7473def assert_interval_array_equal (
7574 left : IntervalArray ,
7675 right : IntervalArray ,
77- exact : bool | Literal ["equiv" ] = ... ,
78- obj : str = ... ,
76+ exact : bool | Literal ["equiv" ] = "equiv" ,
77+ obj : str = "IntervalArray" ,
7978) -> None : ...
8079def assert_period_array_equal (
81- left : PeriodArray , right : PeriodArray , obj : str = ...
80+ left : PeriodArray , right : PeriodArray , obj : str = "PeriodArray"
8281) -> None : ...
8382def assert_datetime_array_equal (
84- left : DatetimeArray , right : DatetimeArray , check_freq : bool = ...
83+ left : DatetimeArray ,
84+ right : DatetimeArray ,
85+ obj : str = "DatetimeArray" ,
86+ check_freq : bool = True ,
8587) -> None : ...
8688def assert_timedelta_array_equal (
87- left : TimedeltaArray , right : TimedeltaArray , check_freq : bool = ...
89+ left : TimedeltaArray ,
90+ right : TimedeltaArray ,
91+ obj : str = "TimedeltaArray" ,
92+ check_freq : bool = True ,
8893) -> None : ...
8994def assert_numpy_array_equal (
9095 left ,
9196 right ,
92- strict_nan : bool = ... ,
93- check_dtype : bool | Literal ["equiv" ] = ... ,
94- err_msg : str | None = ... ,
95- check_same : Literal ["copy" , "same" ] | None = ... ,
96- obj : str = ... ,
97- index_values : Index | np .ndarray | None = ... ,
97+ strict_nan : bool = False ,
98+ check_dtype : bool | Literal ["equiv" ] = True ,
99+ err_msg : str | None = None ,
100+ check_same : Literal ["copy" , "same" ] | None = None ,
101+ obj : str = "numpy array" ,
102+ index_values : Index | np .ndarray | None = None ,
98103) -> None : ...
99104def assert_extension_array_equal (
100105 left : ExtensionArray ,
101106 right : ExtensionArray ,
102- check_dtype : bool | Literal ["equiv" ] = ... ,
103- index_values : Index | np .ndarray | None = ... ,
104- check_exact : bool = ... ,
105- rtol : float = ... ,
106- atol : float = ... ,
107- obj : str = ... ,
107+ check_dtype : bool | Literal ["equiv" ] = True ,
108+ index_values : Index | np .ndarray | None = None ,
109+ check_exact : bool = False ,
110+ rtol : float = 1e-5 ,
111+ atol : float = 1e-8 ,
112+ obj : str = "ExtensionArray" ,
108113) -> None : ...
109114@overload
110115def assert_series_equal (
@@ -151,21 +156,21 @@ def assert_series_equal(
151156def assert_frame_equal (
152157 left : DataFrame ,
153158 right : DataFrame ,
154- check_dtype : bool | Literal ["equiv" ] = ... ,
155- check_index_type : bool | Literal ["equiv" ] = ... ,
156- check_column_type : bool | Literal ["equiv" ] = ... ,
157- check_frame_type : bool = ... ,
158- check_names : bool = ... ,
159- by_blocks : bool = ... ,
160- check_exact : bool = ... ,
161- check_datetimelike_compat : bool = ... ,
162- check_categorical : bool = ... ,
163- check_like : bool = ... ,
164- check_freq : bool = ... ,
165- check_flags : bool = ... ,
166- rtol : float = ... ,
167- atol : float = ... ,
168- obj : str = ... ,
159+ check_dtype : bool | Literal ["equiv" ] = True ,
160+ check_index_type : bool | Literal ["equiv" ] = "equiv" ,
161+ check_column_type : bool | Literal ["equiv" ] = "equiv" ,
162+ check_frame_type : bool = True ,
163+ check_names : bool = True ,
164+ by_blocks : bool = False ,
165+ check_exact : bool = False ,
166+ check_datetimelike_compat : bool = False ,
167+ check_categorical : bool = True ,
168+ check_like : bool = False ,
169+ check_freq : bool = True ,
170+ check_flags : bool = True ,
171+ rtol : float = 1e-5 ,
172+ atol : float = 1e-8 ,
173+ obj : str = "DataFrame" ,
169174) -> None : ...
170175def assert_equal (left , right , ** kwargs ) -> None : ...
171176def assert_sp_array_equal (left : SparseArray , right : SparseArray ) -> None : ...
@@ -178,12 +183,10 @@ def assert_produces_warning(
178183 ) = ...,
179184 filter_level : Literal [
180185 "error" , "ignore" , "always" , "default" , "module" , "once"
181- ] = ... ,
182- check_stacklevel : bool = ... ,
183- raise_on_extra_warnings : bool = ... ,
186+ ] = "always" ,
187+ check_stacklevel : bool = True ,
188+ raise_on_extra_warnings : bool = True ,
184189 match : str | None = None ,
185190) -> Generator [list [warnings .WarningMessage ], None , None ]: ...
186191@contextmanager
187- def ensure_clean (
188- filename : str | None = ..., return_filelike : bool = ..., ** kwargs : Any
189- ) -> Generator [str , None , None ]: ...
192+ def ensure_clean (filename : str | None = None ) -> Generator [str , None , None ]: ...
0 commit comments