modified test.py, added basic database functionality