use stubbing rather than changes to production code to handle Resolv