Skip to content

Commit

Permalink
TST: Create compressed salary testing data (#14587)
Browse files Browse the repository at this point in the history
  • Loading branch information
dhimmel authored and jorisvandenbossche committed Nov 11, 2016
1 parent 06b35db commit 85a6464
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions pandas/io/tests/parser/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -630,18 +630,18 @@ def test_read_csv_parse_simple_list(self):
def test_url(self):
# HTTP(S)
url = ('https://raw.github.com/pandas-dev/pandas/master/'
'pandas/io/tests/parser/data/salary.table.csv')
'pandas/io/tests/parser/data/salaries.csv')
url_table = self.read_table(url)
dirpath = tm.get_data_path()
localtable = os.path.join(dirpath, 'salary.table.csv')
localtable = os.path.join(dirpath, 'salaries.csv')
local_table = self.read_table(localtable)
tm.assert_frame_equal(url_table, local_table)
# TODO: ftp testing

@tm.slow
def test_file(self):
dirpath = tm.get_data_path()
localtable = os.path.join(dirpath, 'salary.table.csv')
localtable = os.path.join(dirpath, 'salaries.csv')
local_table = self.read_table(localtable)

try:
Expand Down
File renamed without changes.
Binary file added pandas/io/tests/parser/data/salaries.csv.bz2
Binary file not shown.
File renamed without changes.
Binary file added pandas/io/tests/parser/data/salaries.csv.xz
Binary file not shown.
Binary file added pandas/io/tests/parser/data/salaries.csv.zip
Binary file not shown.
6 changes: 3 additions & 3 deletions pandas/io/tests/parser/test_network.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ class TestUrlGz(tm.TestCase):

def setUp(self):
dirpath = tm.get_data_path()
localtable = os.path.join(dirpath, 'salary.table.csv')
localtable = os.path.join(dirpath, 'salaries.csv')
self.local_table = read_table(localtable)

@tm.network
def test_url_gz(self):
url = ('https://raw.github.com/pandas-dev/pandas/'
'master/pandas/io/tests/parser/data/salary.table.gz')
'master/pandas/io/tests/parser/data/salaries.csv.gz')
url_table = read_table(url, compression="gzip", engine="python")
tm.assert_frame_equal(url_table, self.local_table)

@tm.network
def test_url_gz_infer(self):
url = 'https://s3.amazonaws.com/pandas-test/salary.table.gz'
url = 'https://s3.amazonaws.com/pandas-test/salaries.csv.gz'
url_table = read_table(url, compression="infer", engine="python")
tm.assert_frame_equal(url_table, self.local_table)

Expand Down

0 comments on commit 85a6464

Please sign in to comment.