added Tests and fixed SurveyDao