mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Test ensuring text isnt rendered when text-opacity 0
This commit is contained in:
@@ -19,10 +19,9 @@ def test_simple_text_opacity(text):
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
def test_value_zero_sets_foreground_color_to_background_color(text):
|
def test_value_zero_doesnt_render_the_text(text):
|
||||||
foreground = background = "0;255;0"
|
|
||||||
assert render(TextOpacity(text, opacity=0)) == (
|
assert render(TextOpacity(text, opacity=0)) == (
|
||||||
f"\x1b[38;2;{foreground};48;2;{background}mHello, world!{STOP}"
|
f"\x1b[48;2;0;255;0m {STOP}"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user