Skip to content

Commit

Permalink
fix invalid escapes
Browse files Browse the repository at this point in the history
  • Loading branch information
wimglenn committed Aug 12, 2022
1 parent 5d3f600 commit 90a7224
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/render.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from rich.console import Console, RenderableType


re_link_ids = re.compile(r"id=[\d\.\-]*?;.*?\x1b")
re_link_ids = re.compile(r"id=[\d.\-]*?;.*?\x1b")


def replace_link_ids(render: str) -> str:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_markup.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def test_markup_error():


def test_markup_escape():
result = str(render("[dim white]\[url=[/]"))
result = str(render("[dim white][url=[/]"))
assert result == "[url="


Expand Down
2 changes: 1 addition & 1 deletion tests/test_traceback.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def level2():
"│" + (" " * 98) + "│",
)
for frame_start in re.finditer(
"^│ .+rich/tests/test_traceback\.py:",
"^│ .+rich/tests/test_traceback.py:",
rendered_exception,
flags=re.MULTILINE,
):
Expand Down

0 comments on commit 90a7224

Please sign in to comment.