refactored assertions