Write database tests for twisted adbapi for GetTor

We discussed moving to a different sqlite3 api, but after talking with @meejah, it's a bad idea to mix and match twisted with other I/O operations.

So, we're opting to stay with twisted, write some tests that work, and see whether we need to make changes to how dbpool is called and used.