Title: gh-138013: Remove `test_io` load_tests namespace manipulation by cmaloney · Pull Request #138366 · python/cpython · GitHub
Open Graph Title: gh-138013: Remove `test_io` load_tests namespace manipulation by cmaloney · Pull Request #138366 · python/cpython
X Title: gh-138013: Remove `test_io` load_tests namespace manipulation by cmaloney · Pull Request #138366 · python/cpython
Description: Reduce what happens in load_tests so that the next change, moving the Buffered* tests to test_bufferdio is purely mechanical movement and updating imports. This adds two classes, one per I/O implementation, to act as dispatch to the implementation-specific mocks as well as module members. Previously the mappings CTestCase and PyTestCase provide were injected directly during load_tests. CTestCase and PyTestCase inherit from unittest.TestCase so when the split happens default test discovery will work for the classes in test_bufferedio. test_general keeps a manual test list for this refactoring; some of the tests (ex. ProtocolsTest) aren't currently run and fixing that + helpers to not be picked up as tests is out of my current scope. CTestCase and PyTestCase have an io class member which points to the implementation meaning that can be removed from individual test cases which now inherit from them. Tested locally with ./python -m test test_io -uall,walltime,largefile,extralargefile -M16G -j8 -v Could this get skip news as its a test-only change? Could buildbots be run against this? Worried there are lots of platform-specific cases in these test cases and would rather proactively debug/fix than reactively (Ex. 4 tests are skipped for me on my 64 bit Linux box because: "only run in 32-bit address space" and "only when utf-8 mode is disabled") Issue: gh-138013
Open Graph Description: Reduce what happens in load_tests so that the next change, moving the Buffered* tests to test_bufferdio is purely mechanical movement and updating imports. This adds two classes, one per I/O implem...
X Description: Reduce what happens in load_tests so that the next change, moving the Buffered* tests to test_bufferdio is purely mechanical movement and updating imports. This adds two classes, one per I/O implem...
Opengraph URL: https://github.com/python/cpython/pull/138366
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:40d22ee6-fca2-ea7f-b83a-e2ec22064f46 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 97D0:6435C:AB97930:EFF657E:6A50F16A |
| html-safe-nonce | 16e694f90b9571defe183fe7c5d3121eec6e51949b78701de0054c2d7e834d73 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5N0QwOjY0MzVDOkFCOTc5MzA6RUZGNjU3RTo2QTUwRjE2QSIsInZpc2l0b3JfaWQiOiI4NTU4NjY2ODE1MjU2OTgxODY2IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 477dc6e9770c93b3e2b96d7d09ed678d880a81e3f82b3e534d6b444464927253 |
| hovercard-subject-tag | pull_request:2791194543 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/python/cpython/pull/138366/files |
| twitter:image | https://avatars.githubusercontent.com/u/751088?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/751088?s=400&v=4 |
| og:image:alt | Reduce what happens in load_tests so that the next change, moving the Buffered* tests to test_bufferdio is purely mechanical movement and updating imports. This adds two classes, one per I/O implem... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 5266e58c17a510c403505cc811606465e90a881d2007ee7df1c4800d5c659838 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 5ec60191a48933536a90c8a19f47142fcd0d4739 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width