Tidy up expectations and fix all warnings.