Commit 24685bcf authored by Denis Bilenko's avatar Denis Bilenko

add a test case exposing issue #24. Thanks to Ted Suzman.

http://code.google.com/p/gevent/issues/detail?id=24
parent 5bb09bbc
from gevent import monkey; monkey.patch_all()
import threading
localdata = threading.local()
localdata.x = "hello"
success = []
def func():
try:
localdata.x
raise AssertionError('localdata.x must raise AttributeError')
except AttributeError:
pass
assert localdata.__dict__ == {}, localdata.__dict__
success.append(1)
t = threading.Thread(None, func)
t.start()
t.join()
assert success == [1], 'test failed'
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment