Some general work

Cleanups
Unit Testing Mockups
Basic DB operations