Skip to content

Commit c3b72aa

Browse files
DOC: Add docstrings to fixtures in /series/methods/test_drop_duplicates.py (#59265)
* Add docstrings to fixtures in /series/methods/test_drop_duplicates.py * fixup! Add docstrings to fixtures in /series/methods/test_drop_duplicates.py
1 parent 7a4a7bf commit c3b72aa

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

pandas/tests/series/methods/test_drop_duplicates.py

+9-1
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,16 @@ class TestSeriesDropDuplicates:
7575
params=["int_", "uint", "float64", "str_", "timedelta64[h]", "datetime64[D]"]
7676
)
7777
def dtype(self, request):
78+
"""
79+
Fixture that provides different data types for testing.
80+
"""
7881
return request.param
7982

8083
@pytest.fixture
8184
def cat_series_unused_category(self, dtype, ordered):
85+
"""
86+
Fixture that creates a Categorical Series with some unused categories.
87+
"""
8288
# Test case 1
8389
cat_array = np.array([1, 2, 3, 4, 5], dtype=np.dtype(dtype))
8490

@@ -141,7 +147,9 @@ def test_drop_duplicates_categorical_non_bool_keepfalse(
141147

142148
@pytest.fixture
143149
def cat_series(self, dtype, ordered):
144-
# no unused categories, unlike cat_series_unused_category
150+
"""
151+
Fixture that creates a Categorical Series with no unused categories.
152+
"""
145153
cat_array = np.array([1, 2, 3, 4, 5], dtype=np.dtype(dtype))
146154

147155
input2 = np.array([1, 2, 3, 5, 3, 2, 4], dtype=np.dtype(dtype))

0 commit comments

Comments
 (0)