Remove death code and other changes to increase test coverage