Stub File.exist? instead of File.exists?
Do not globally stub all File calls, only ones to expected host file paths
The "removes the duplicate hostnames" test should now be expecting the 3rd (not 2nd) entry to be removed - update expectation to generically find the example.com entry
Stub File.exist? instead of File.exists? Do not globally stub all File calls, only ones to expected host file paths
The "removes the duplicate hostnames" test should now be expecting the 3rd (not 2nd) entry to be removed - update expectation to generically find the example.com entry