fix this test to actually test something (closes #13606)

Thanks Mark Shannon.
This commit is contained in:
Benjamin Peterson 2011-12-15 15:57:15 -05:00
parent 57c9c7b755
commit ca81bf76e5
1 changed files with 4 additions and 2 deletions

View File

@ -70,9 +70,11 @@ class ModuleTests(unittest.TestCase):
m = ModuleType("foo")
m.destroyed = destroyed
s = """class A:
def __init__(self, l):
self.l = l
def __del__(self):
destroyed.append(1)
a = A()"""
self.l.append(1)
a = A(destroyed)"""
exec(s, m.__dict__)
del m
gc_collect()