Improve unit test coverage