Skip to content

Instantly share code, notes, and snippets.

@sekimura
Created February 16, 2012 23:25
Show Gist options
  • Save sekimura/1848716 to your computer and use it in GitHub Desktop.
Save sekimura/1848716 to your computer and use it in GitHub Desktop.
INC = 'hoho'
class Foo(object):
def __init__(self):
self._mock = INC
def __del__(self):
print self
if self._mock == INC:
print 'got hoho', self._mock, INC
else:
print 'no hoho'
import time
from foo import Foo
if __name__ == '__main__':
while True:
f = Foo()
time.sleep(1000)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment