Simplify stubbing options.exit and remove duplicate test