Fixes based on failing unit tests.