Skip to content

Commit 216a36e

Browse files
committed
added regression test
1 parent 4a5feba commit 216a36e

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

test/test_regression.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -512,3 +512,14 @@ def test_numpy_int64_as_integer():
512512
assert_equal(expected, result)
513513
except ImportError:
514514
raise skip("")
515+
516+
def test_empty_table_with_colalign():
517+
"Regression: empty table with colalign kwarg"
518+
table = tabulate([], ["a", "b", "c"], colalign=("center", "left", "left", "center"))
519+
expected = "\n".join(
520+
[
521+
"a b c",
522+
"--- --- ---",
523+
]
524+
)
525+
assert_equal(expected, table)

0 commit comments

Comments
 (0)