Title: Mark slow test methods with @requires_resource('cpu') · Issue #108416 · python/cpython · GitHub
Open Graph Title: Mark slow test methods with @requires_resource('cpu') · Issue #108416 · python/cpython
X Title: Mark slow test methods with @requires_resource('cpu') · Issue #108416 · python/cpython
Description: Has this already been discussed elsewhere? This is a minor feature, which does not need previous discussion elsewhere Links to previous discussion of this feature: No response Proposal: The proposed PR marks all test methods which have d...
Open Graph Description: Has this already been discussed elsewhere? This is a minor feature, which does not need previous discussion elsewhere Links to previous discussion of this feature: No response Proposal: The propose...
X Description: Has this already been discussed elsewhere? This is a minor feature, which does not need previous discussion elsewhere Links to previous discussion of this feature: No response Proposal: The propose...
Opengraph URL: https://github.com/python/cpython/issues/108416
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Mark slow test methods with @requires_resource('cpu')","articleBody":"### Has this already been discussed elsewhere?\n\nThis is a minor feature, which does not need previous discussion elsewhere\n\n### Links to previous discussion of this feature:\n\n_No response_\n\n### Proposal:\n\nThe proposed PR marks all test methods which have duration longer than 3 seconds with `@test.support.requires_resource('cpu')` decorator.\r\n\r\nThe purpose is to reduce manual testing time. It happens that all tests in a file are ran in fraction of a second, but few tests take a long time to run. When you work on some large feature or bugfix you need to run corresponding tests multiple times. You can exclude the slowest tests manually, but you should know what of them are culprits. When they are marked as CPU-hungry, you can just not enable the \"cpu\" resource.\r\n\r\nFor example, all `test_math` takes over 1.5 minutes to finish. But when exclude `test_sumprod_stress`, it takes only 3 seconds.\n\n\u003c!-- gh-linked-prs --\u003e\n### Linked PRs\n* gh-108421\n* gh-108480\n* gh-108798\n* gh-108799\n* gh-108923\n* gh-108924\n\u003c!-- /gh-linked-prs --\u003e\n","author":{"url":"https://github.com/serhiy-storchaka","@type":"Person","name":"serhiy-storchaka"},"datePublished":"2023-08-24T12:30:50.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":7},"url":"https://github.com/108416/cpython/issues/108416"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:2382d150-f591-2f96-eaa9-046884a2cc2d |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B546:6114D:115A2FA:17FCC6C:6969FE34 |
| html-safe-nonce | a99020d866dc66a27ad02c3aff17560a88f56b6a7f208660b53ce50654ef9cc2 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNTQ2OjYxMTREOjExNUEyRkE6MTdGQ0M2Qzo2OTY5RkUzNCIsInZpc2l0b3JfaWQiOiIzOTc0OTgzMDA0MzMxODM0OTMyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | b96bfba44f49f1b65c84d01fe0de711bbd621513a243fba6c79313cc0f32c371 |
| hovercard-subject-tag | issue:1865056888 |
| github-keyboard-shortcuts | repository,issues,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/_view_fragments/issues/show/python/cpython/108416/issue_layout |
| twitter:image | https://opengraph.githubassets.com/28115f59a82d61e0e9ae10830e2acfb53245e0406f779ce3d386889033cb9f2c/python/cpython/issues/108416 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/28115f59a82d61e0e9ae10830e2acfb53245e0406f779ce3d386889033cb9f2c/python/cpython/issues/108416 |
| og:image:alt | Has this already been discussed elsewhere? This is a minor feature, which does not need previous discussion elsewhere Links to previous discussion of this feature: No response Proposal: The propose... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | serhiy-storchaka |
| hostname | github.com |
| expected-hostname | github.com |
| None | 7b32f1c7c4549428ee399213e8345494fc55b5637195d3fc5f493657579235e8 |
| turbo-cache-control | no-preview |
| 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 | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | bdde15ad1b403e23b08bbd89b53fbe6bdf688cad |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width