PHPUnit Tests

Restructuring of db files to accommodate for multiple database handlers,
as well as beginning of PHPUnit tests.