| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
The documented options of ``python -m ensurepip`` (--upgrade, --user, --root, --altinstall, --default-pip, --verbose) were only tested through bootstrap(), not through the command line. Drive each one through _main() with pip mocked, including the altinstall/default-pip conflict, --help and an unknown option.
|
The "Sanitizers / TSan (free-threading)" failure is unrelated to this change: test_asyncio.test_taskgroups.test_taskgroup_cancel_keeps_outer_cancellation lost its cancellation message under the slow build. Reported as gh-157157 with a fix in #157158. |
Sorry, something went wrong.
|
Dropped the NEWS entry: this changes only tests, which the devguide lists among the exemptions. The same point was made on #157171 ("This is a fix to unreleased test. It does not need a NEWS entry") and on #157158, so I am applying it across my open test-only PRs rather than having it raised on each one. bedevere/news will stay red until skip news is applied. (Edited to remove two user mentions that pinged core developers for no reason. Sorry for the noise.) |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
The documented command-line interface of ensurepip has six options, but test_ensurepip.py only called _main() with --version and with no arguments. The options themselves were covered only through bootstrap(), so a mistake in the argument parser or in how _main() forwards the parsed options would not have been caught.
This adds tests to the existing TestBootstrappingMainFunction class, one per documented option, in the same style as the TestBootstrap tests (pip is mocked, the arguments passed to pip and ENSUREPIP_OPTIONS are asserted):
Tests-only; a NEWS entry is included in the Tests section like the earlier PRs in this series that shipped one.
Ran test_ensurepip (also with -R 3:3), make patchcheck and the pre-commit hooks on macOS.