Skip to content

Commit 5af8b2d

Browse files
mroeschkenoatamir
authored andcommitted
TST/CI: Fix PerformanceWarning checking for string[pyarrow] (pandas-dev#48171)
TST/CI: Fix PerformanceWarning checking for string[pyarrow[
1 parent 405aa03 commit 5af8b2d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

pandas/tests/extension/test_string.py

+8
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,7 @@ def test_argsort(self, data_for_sorting):
175175
PerformanceWarning,
176176
pa_version_under7p0
177177
and getattr(data_for_sorting.dtype, "storage", "") == "pyarrow",
178+
check_stacklevel=False,
178179
):
179180
super().test_argsort(data_for_sorting)
180181

@@ -183,6 +184,7 @@ def test_argsort_missing(self, data_missing_for_sorting):
183184
PerformanceWarning,
184185
pa_version_under7p0
185186
and getattr(data_missing_for_sorting.dtype, "storage", "") == "pyarrow",
187+
check_stacklevel=False,
186188
):
187189
super().test_argsort_missing(data_missing_for_sorting)
188190

@@ -262,6 +264,7 @@ def test_argsort_missing_array(self, data_missing_for_sorting):
262264
PerformanceWarning,
263265
pa_version_under7p0
264266
and getattr(data_missing_for_sorting.dtype, "storage", "") == "pyarrow",
267+
check_stacklevel=False,
265268
):
266269
super().test_argsort_missing(data_missing_for_sorting)
267270

@@ -278,6 +281,7 @@ def test_nargsort(self, data_missing_for_sorting, na_position, expected):
278281
PerformanceWarning,
279282
pa_version_under7p0
280283
and getattr(data_missing_for_sorting.dtype, "storage", "") == "pyarrow",
284+
check_stacklevel=False,
281285
):
282286
super().test_nargsort(data_missing_for_sorting, na_position, expected)
283287

@@ -287,6 +291,7 @@ def test_sort_values(self, data_for_sorting, ascending, sort_by_key):
287291
PerformanceWarning,
288292
pa_version_under7p0
289293
and getattr(data_for_sorting.dtype, "storage", "") == "pyarrow",
294+
check_stacklevel=False,
290295
):
291296
super().test_sort_values(data_for_sorting, ascending, sort_by_key)
292297

@@ -298,6 +303,7 @@ def test_sort_values_missing(
298303
PerformanceWarning,
299304
pa_version_under7p0
300305
and getattr(data_missing_for_sorting.dtype, "storage", "") == "pyarrow",
306+
check_stacklevel=False,
301307
):
302308
super().test_sort_values_missing(
303309
data_missing_for_sorting, ascending, sort_by_key
@@ -309,6 +315,7 @@ def test_sort_values_frame(self, data_for_sorting, ascending):
309315
PerformanceWarning,
310316
pa_version_under7p0
311317
and getattr(data_for_sorting.dtype, "storage", "") == "pyarrow",
318+
check_stacklevel=False,
312319
):
313320
super().test_sort_values_frame(data_for_sorting, ascending)
314321

@@ -367,6 +374,7 @@ def test_groupby_extension_transform(self, data_for_grouping):
367374
PerformanceWarning,
368375
pa_version_under7p0
369376
and getattr(data_for_grouping.dtype, "storage", "") == "pyarrow",
377+
check_stacklevel=False,
370378
):
371379
super().test_groupby_extension_transform(data_for_grouping)
372380

0 commit comments

Comments
 (0)