Fix test.py throwing exceptions.
Fix test.py throwing exceptions.

Also checked that the testing framework works on python 2.7 and latest python
3. Appears to work. Yay.

traildb/traildb,tuulos/traildb,tuulos/traildb,traildb/traildb,tuulos/traildb,traildb/traildb,tuulos/traildb