Mercurial > p > roundup > code
comparison roundup/test/memorydb.py @ 6493:a7072cf4ad7e
Actually call close().
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Mon, 06 Sep 2021 16:35:22 -0400 |
| parents | 4351c95faace |
| children | 408fd477761f |
comparison
equal
deleted
inserted
replaced
| 6492:4351c95faace | 6493:a7072cf4ad7e |
|---|---|
| 60 initial_data = os.path.join(prefix, 'initial_data.py') | 60 initial_data = os.path.join(prefix, 'initial_data.py') |
| 61 vars = dict(db=db, admin_email='admin@test.com', | 61 vars = dict(db=db, admin_email='admin@test.com', |
| 62 adminpw=password.Password('sekrit')) | 62 adminpw=password.Password('sekrit')) |
| 63 fd = open(initial_data) | 63 fd = open(initial_data) |
| 64 exec(compile(fd.read(), initial_data, 'exec'), vars) | 64 exec(compile(fd.read(), initial_data, 'exec'), vars) |
| 65 fd.close | 65 fd.close() |
| 66 | 66 |
| 67 # load standard detectors | 67 # load standard detectors |
| 68 dirname = os.path.join(prefix, 'detectors') | 68 dirname = os.path.join(prefix, 'detectors') |
| 69 for fn in os.listdir(dirname): | 69 for fn in os.listdir(dirname): |
| 70 if not fn.endswith('.py'): continue | 70 if not fn.endswith('.py'): continue |
