Skip to content

Commit

Permalink
Update test_readme.py
Browse files Browse the repository at this point in the history
Change the README filename and update the regex
  • Loading branch information
bskinn committed May 9, 2024
1 parent 44116a3 commit b80cdf1
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/test_readme.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@

p_shell = re.compile(
r"""
\n\s+[$](?P<cmd>.*) # Entered command
\n```(\w+)?
\n\s*[$](?P<cmd>.*) # Entered command
(?P<out>(\n.*)+?) # Line(s) of output
(?=\n\.\.) # Lookahead for explicit shell block endpoint
(?=\n```) # Lookahead for explicit shell block endpoint
""",
re.X,
)
Expand Down Expand Up @@ -85,7 +86,7 @@ def test_readme_shell_cmds(ensure_doc_scratch, is_win, check):
if is_win and sys.version_info < (3, 9): # pragma: no cover
pytest.skip("Windows mishandles stdout/stderr for Python < 3.9")

text = Path("README.rst").read_text()
text = Path("README.md").read_text()

chk = dt.OutputChecker()

Expand Down

0 comments on commit b80cdf1

Please sign in to comment.