MCPcopy
hub / github.com/Textualize/rich / test_stylize_before

Function test_stylize_before

tests/test_text.py:149–153  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

147
148
149def test_stylize_before():
150 text = Text("Hello, World!")
151 text.stylize("bold", 0, 5)
152 text.stylize_before("italic", 2, 7)
153 assert text._spans == [Span(2, 7, "italic"), Span(0, 5, "bold")]
154
155
156def test_stylize_negative_index():

Callers

nothing calls this directly

Calls 4

stylizeMethod · 0.95
stylize_beforeMethod · 0.95
TextClass · 0.90
SpanClass · 0.90

Tested by

no test coverage detected