Skip to content

Commit

Permalink
Add docs label for markdown files (#657)
Browse files Browse the repository at this point in the history
Co-authored-by: Hugo van Kemenade <[email protected]>
Co-authored-by: Adam Turner <[email protected]>
  • Loading branch information
3 people authored Dec 11, 2024
1 parent 494d3de commit f26f464
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bedevere/prtype.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async def classify_by_filepaths(gh, pull_request, filenames):
if util.is_news_dir(filename):
news = True
filepath = pathlib.PurePath(filename)
if filepath.suffix == ".rst" or filepath.name == ".nitignore":
if filepath.suffix in {".md", ".rst"} or filepath.name == ".nitignore":
docs = True
elif filepath.name.startswith(("test_", "_test")):
tests = True
Expand Down
2 changes: 1 addition & 1 deletion tests/test_prtype.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ async def test_news_only():


async def test_docs_no_news():
filenames = {"path/to/docs1.rst"}
filenames = {"path/to/docs1.rst", "other/path/to/docs2.md"}
issue = {"labels": [], "labels_url": "https://api.github.com/some/label"}
gh = FakeGH(getitem=issue)
event_data = {
Expand Down

0 comments on commit f26f464

Please sign in to comment.