diff --git a/lib/capybara/apparition/browser/launcher/local.rb b/lib/capybara/apparition/browser/launcher/local.rb index 0264bc6..816685d 100644 --- a/lib/capybara/apparition/browser/launcher/local.rb +++ b/lib/capybara/apparition/browser/launcher/local.rb @@ -40,7 +40,7 @@ def initialize(headless:, **options) @options.merge!(HEADLESS_OPTIONS) @options['disable-gpu'] = nil if Capybara::Apparition.windows? end - @options['user-data-dir'] = Dir.mktmpdir + @options['user-data-dir'] ||= Dir.mktmpdir end def start