tests/config.py
author Radek Brich <radek.brich@devl.cz>
Sat, 29 Sep 2012 12:08:47 +0200
changeset 48 b82c7c2fb5af
parent 37 5b0eb4b11940
child 49 08e4dfe1b0cb
permissions -rw-r--r--
PgManager: Fix logging, log queries before executing, possible exceptions are logged after. Add tests for RowDict. Add tests.py - runs all tests.

import sys

sys.path.insert(0, '..')


class Config(dict):
    def __init__(self, fname):
        with open(fname) as f:
            data = f.read()
        exec(data, dict(), self)