Skip to content

Commit 5b6b346

Browse files
authored
TST: Check error message in overlapping bins test (#24029)
Follow-up to gh-23999. xref gh-23922.
1 parent fa547d8 commit 5b6b346

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pandas/tests/reshape/test_tile.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,11 @@ def test_bins_from_intervalindex(self):
9292
np.array([1, 1, 2], dtype='int8'))
9393

9494
def test_bins_not_overlapping_from_intervalindex(self):
95-
# verify if issue 23980 is properly solved.
95+
# see gh-23980
96+
msg = "Overlapping IntervalIndex is not accepted"
9697
ii = IntervalIndex.from_tuples([(0, 10), (2, 12), (4, 14)])
97-
with pytest.raises(ValueError):
98+
99+
with pytest.raises(ValueError, match=msg):
98100
cut([5, 6], bins=ii)
99101

100102
def test_bins_not_monotonic(self):

0 commit comments

Comments
 (0)