Skip to content

gh-131178: Add CLI tests for pydoc module#151971

Open
tangyuan0821 wants to merge 2 commits into
python:mainfrom
tangyuan0821:131178-pydoc
Open

gh-131178: Add CLI tests for pydoc module#151971
tangyuan0821 wants to merge 2 commits into
python:mainfrom
tangyuan0821:131178-pydoc

Conversation

@tangyuan0821

@tangyuan0821 tangyuan0821 commented Jun 23, 2026

Copy link
Copy Markdown
Contributor
  • Add TestPydocCLI in Lib/test/test_pydoc/test_pydoc.py covering
    pydoc <name>, -k, -w, missing arguments, and invalid flags.
  • Fix Lib/pydoc.py to call sys.exit(1) on BadUsage/getopt.error.

Tests:

./python.exe -m test test_pydoc -v
# 127 tests OK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant