making it unit test friendly