added more tests and fixed but for deleting a badge with attached projects