diff --git a/pandas/tests/io/parser/python_parser_only.py b/pandas/tests/io/parser/python_parser_only.py index 590736f720e67a..6a41b4636e5324 100644 --- a/pandas/tests/io/parser/python_parser_only.py +++ b/pandas/tests/io/parser/python_parser_only.py @@ -8,6 +8,7 @@ """ import csv +import sys import pytest @@ -230,6 +231,7 @@ def test_multi_char_sep_quotes(self): self.read_csv(StringIO(data), sep=',,', quoting=csv.QUOTE_NONE) + @tm.capture_stderr def test_none_delimiter(self): # see gh-13374 and gh-17465 @@ -247,6 +249,9 @@ def test_none_delimiter(self): warn_bad_lines=True) tm.assert_frame_equal(result, expected) + warning = sys.stderr.getvalue() + assert 'Skipping line 3' in warning + def test_skipfooter_bad_row(self): # see gh-13879 # see gh-15910