8000 [3.12] gh-104812: Run Pending Calls in any Thread (gh-104813) by ericsnowcurrently · Pull Request #105752 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

[3.12] gh-104812: Run Pending Calls in any Thread (gh-104813) #105752

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Skip tests if no threading.
  • Loading branch information
ericsnowcurrently committed Jun 14, 2023
commit a0786b8ebb40f7b975f09cd833930ccb2372427e
2 changes: 2 additions & 0 deletions Lib/test/test_capi/test_misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -1407,6 +1407,7 @@ def wait_for_result(self):
while self.result is None:
time.sleep(0.01)

@threading_helper.requires_working_threading()
def test_subthreads_can_handle_pending_calls(self):
payload = 'Spam spam spam spam. Lovely spam! Wonderful spam!'

Expand All @@ -1422,6 +1423,7 @@ def do_the_work():

self.assertEqual(task.result, payload)

@threading_helper.requires_working_threading()
def test_many_subthreads_can_handle_pending_calls(self):
main_tid = threading.get_ident()
self.assertEqual(threading.main_thread().ident, main_tid)
Expand Down
0