From b93325ee425d473a2e023029810cc077ee31c97c Mon Sep 17 00:00:00 2001 From: gfyoung Date: Mon, 8 Aug 2016 21:42:28 -0400 Subject: [PATCH] TST: Removed regex warning for read_csv --- pandas/io/tests/parser/common.py | 14 ++++++++++++++ pandas/io/tests/parser/python_parser_only.py | 14 -------------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/pandas/io/tests/parser/common.py b/pandas/io/tests/parser/common.py index 7558e4bb63226..619ac7b4c77ef 100644 --- a/pandas/io/tests/parser/common.py +++ b/pandas/io/tests/parser/common.py @@ -1568,3 +1568,17 @@ def _encode_data_with_bom(_data): encoding=utf8, names=['a'], skip_blank_lines=False) tm.assert_frame_equal(out, expected) + + def test_temporary_file(self): + # see gh-13398 + data1 = "0 0" + + from tempfile import TemporaryFile + new_file = TemporaryFile("w+") + new_file.write(data1) + new_file.flush() + new_file.seek(0) + + result = self.read_csv(new_file, sep='\s+', header=None) + expected = DataFrame([[0, 0]]) + tm.assert_frame_equal(result, expected) diff --git a/pandas/io/tests/parser/python_parser_only.py b/pandas/io/tests/parser/python_parser_only.py index 619b6b63568f3..a7389fd174e1d 100644 --- a/pandas/io/tests/parser/python_parser_only.py +++ b/pandas/io/tests/parser/python_parser_only.py @@ -172,20 +172,6 @@ def test_read_table_buglet_4x_multiindex(self): actual = self.read_table(StringIO(data), sep='\s+') tm.assert_frame_equal(actual, expected) - def test_temporary_file(self): - # GH13398 - data1 = "0 0" - - from tempfile import TemporaryFile - new_file = TemporaryFile("w+") - new_file.write(data1) - new_file.flush() - new_file.seek(0) - - result = self.read_csv(new_file, sep=r"\s*", header=None) - expected = DataFrame([[0, 0]]) - tm.assert_frame_equal(result, expected) - def test_skipfooter_with_decimal(self): # see gh-6971 data = '1#2\n3#4'