Skip to content

Commit

Permalink
fix broken test case in python 2
Browse files Browse the repository at this point in the history
  • Loading branch information
chfw committed May 18, 2015
1 parent 8f39ded commit 3f53535
Showing 1 changed file with 14 additions and 16 deletions.
30 changes: 14 additions & 16 deletions tests/test_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,16 @@ def test_load_ods_data():

@raises(NotImplementedError)
def test_load_xls_data_from_memory():
if not PY2:
io = BytesIO()
load_data(io, file_type="xls")
else:
raise NotImplementedError("pass it")
io = BytesIO()
load_data(io, file_type="xls")

@raises(IOError)
def test_load_xlsm_data_from_memory():
io = StringIO()
get_writer(io, file_type="xlsm")

if not PY2:
io = StringIO()
get_writer(io, file_type="xlsm")
else:
raise IOError("pass it")

@raises(NotImplementedError)
def test_write_xlsx_data():
Expand All @@ -46,17 +45,16 @@ def test_write_xlsx_data():

@raises(IOError)
def test_writer_xlsm_data_from_memory():
io = StringIO()
get_writer(io, file_type="xlsm")


@raises(NotImplementedError)
def test_writer_xlsm_data_from_memory2():
if not PY2:
io = BytesIO()
io = StringIO()
get_writer(io, file_type="xlsm")
else:
raise NotImplementedError("pass it")
raise IOError("pass it")

@raises(NotImplementedError)
def test_writer_xlsm_data_from_memory2():
io = BytesIO()
get_writer(io, file_type="xlsm")


def test_get_io():
Expand Down

0 comments on commit 3f53535

Please sign in to comment.