def test_justify(self): res = list(b.justify([['foo', 'bar'], ['a', 'b', 'c']], 8)) self.assertEqual(res, [['foo ', 'bar'], ['a ', 'b ', 'c']])
def test_justify_two_empty_lines(self): res = list(b.justify([[], []], 100)) self.assertEqual(res, [[], []])
def test_justify_one_word_per_line(self): res = list(b.justify([['foo'], ['bar']], 8)) self.assertEqual(res, [['foo'], ['bar']])
def test_justify_empty_no_width(self): res = list(b.justify([[]], 0)) self.assertEqual(res, [[]])
def test_justify_empty(self): res = list(b.justify([[]], 100)) self.assertEqual(res, [[]])