Skip to content

Commit 2c48fc5

Browse files
committed
Add comment about why 'context' is passed in test.
1 parent 872920d commit 2c48fc5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Lib/test/test_decimal.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1726,6 +1726,9 @@ def test_threading(self):
17261726
self.finish1 = threading.Event()
17271727
self.finish2 = threading.Event()
17281728

1729+
# This test wants to start threads with an empty context, no matter
1730+
# the setting of sys.flags.thread_inherit_context. We pass the
1731+
# 'context' argument explicitly with an empty context instance.
17291732
th1 = threading.Thread(target=thfunc1, args=(self,),
17301733
context=contextvars.Context())
17311734
th2 = threading.Thread(target=thfunc2, args=(self,),

0 commit comments

Comments
 (0)