Skip to content

Commit 23f900f

Browse files
committed
add test for label is True
1 parent fdc35f8 commit 23f900f

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

pandas/tests/reshape/test_qcut.py

+8
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,14 @@ def test_qcut_return_intervals():
130130
tm.assert_series_equal(res, exp)
131131

132132

133+
def test_qcut_labels_true():
134+
# issue 13318
135+
values = range(5)
136+
msg = "User desired bin labels must be passed in as an argument, not just `True`"
137+
with pytest.raises(ValueError, match=msg):
138+
qcut(values, 4, labels=True)
139+
140+
133141
@pytest.mark.parametrize(
134142
"kwargs,msg",
135143
[

0 commit comments

Comments
 (0)