diff options
author | dmosberger <davidm@egauge.net> | 2020-12-04 01:10:02 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-04 10:10:02 +0200 |
commit | e8f54811c7128d6ee849d072f27459e9b9322034 (patch) | |
tree | 273d2b67f20021d10ebaa0dcc5d611d282dbe130 /tests/test_tablib.py | |
parent | e8774043ed6496ac9664d0b4cf5bb7305f92c007 (diff) | |
download | tablib-master.tar.gz |
Diffstat (limited to 'tests/test_tablib.py')
-rwxr-xr-x | tests/test_tablib.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/test_tablib.py b/tests/test_tablib.py index b13d17c..ccb28e1 100755 --- a/tests/test_tablib.py +++ b/tests/test_tablib.py @@ -1040,6 +1040,13 @@ class XLSXTests(BaseTestCase): data = tablib.Dataset().load(fh) self.assertEqual(data.headers[0], 'Hello World') + def test_xlsx_bad_dimensions(self): + """Test loading file with bad dimension. Must be done with + read_only=False.""" + xls_source = Path(__file__).parent / 'files' / 'bad_dimensions.xlsx' + with xls_source.open('rb') as fh: + data = tablib.Dataset().load(fh, read_only=False) + self.assertEqual(data.height, 3) class JSONTests(BaseTestCase): def test_json_format_detect(self): |