refactored dao unit tests