Update tests and logic.