mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-29 16:20:11 -04:00
stdpy: Add missing threading.ThreadError
This commit is contained in:
parent
2ce373b0da
commit
c141bef19b
@ -34,6 +34,7 @@ __all__ = [
|
|||||||
'Semaphore', 'BoundedSemaphore',
|
'Semaphore', 'BoundedSemaphore',
|
||||||
'Event',
|
'Event',
|
||||||
'Timer',
|
'Timer',
|
||||||
|
'ThreadError',
|
||||||
'local',
|
'local',
|
||||||
'current_thread',
|
'current_thread',
|
||||||
'main_thread',
|
'main_thread',
|
||||||
@ -46,6 +47,7 @@ TIMEOUT_MAX = _thread.TIMEOUT_MAX
|
|||||||
|
|
||||||
local = _thread._local
|
local = _thread._local
|
||||||
_newname = _thread._newname
|
_newname = _thread._newname
|
||||||
|
ThreadError = _thread.error
|
||||||
|
|
||||||
class ThreadBase:
|
class ThreadBase:
|
||||||
""" A base class for both Thread and ExternalThread in this
|
""" A base class for both Thread and ExternalThread in this
|
||||||
|
7
tests/stdpy/test_threading.py
Normal file
7
tests/stdpy/test_threading.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
from direct.stdpy import threading
|
||||||
|
import pytest
|
||||||
|
|
||||||
|
|
||||||
|
def test_threading_error():
|
||||||
|
with pytest.raises(threading.ThreadError):
|
||||||
|
threading.stack_size()
|
Loading…
x
Reference in New Issue
Block a user