Helpers that makes it easier to unit test primitive interfaces.