Tons of reworking to use a data layer, and setup working unit test