DEV: Set Capybara.default_max_wait_time to 4 as default (#24934)

Why this change?

By default, `Capybara.default_max_wait_time` is set to `2`. However,
this is not a high enough default for Discourse as certain requests like
creating a post can take upwards of 2 seconds even on a high end desktop
CPU like the Ryzen 5950x. Therefore, we have decided to double the default max wait time.
This commit is contained in:
Alan Guo Xiang Tan 2023-12-18 11:51:59 +08:00 committed by GitHub
parent 1f6d778561
commit ac21d8af50
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -304,6 +304,8 @@ RSpec.configure do |config|
if ENV["CAPYBARA_DEFAULT_MAX_WAIT_TIME"].present? if ENV["CAPYBARA_DEFAULT_MAX_WAIT_TIME"].present?
Capybara.default_max_wait_time = ENV["CAPYBARA_DEFAULT_MAX_WAIT_TIME"].to_i Capybara.default_max_wait_time = ENV["CAPYBARA_DEFAULT_MAX_WAIT_TIME"].to_i
else
Capybara.default_max_wait_time = 4
end end
Capybara.threadsafe = true Capybara.threadsafe = true