Some fixes to server app and attepmt to add dbContext tests