mirror of https://github.com/Textualize/rich.git
12 lines
427 B
Python
12 lines
427 B
Python
from rich import cells
|
|
|
|
|
|
def test_set_cell_size():
|
|
assert cells.set_cell_size("foo", 2) == "fo"
|
|
assert cells.set_cell_size("foo", 3) == "foo"
|
|
assert cells.set_cell_size("foo", 4) == "foo "
|
|
assert cells.set_cell_size("😽😽", 4) == "😽😽"
|
|
assert cells.set_cell_size("😽😽", 3) == "😽 "
|
|
assert cells.set_cell_size("😽😽", 2) == "😽"
|
|
assert cells.set_cell_size("😽😽", 1) == " "
|