Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2017-07-27 11:46:59 +0300
committerRémy Coutable <remy@rymai.me>2017-07-27 11:46:59 +0300
commitcbfdc7e3b53c5443a82c78bc69c77ad000648973 (patch)
tree2710ae7e785f4177a349529879de04975761b993 /spec/features/dashboard/issues_spec.rb
parent704ce761f3686d7fee498b92a67a99cfed558ee7 (diff)
Ensure the overriding of Gitlab::Application.routes.default_url_options is only local
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'spec/features/dashboard/issues_spec.rb')
-rw-r--r--spec/features/dashboard/issues_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/features/dashboard/issues_spec.rb b/spec/features/dashboard/issues_spec.rb
index 2a5ef08da60..ea7a9efc326 100644
--- a/spec/features/dashboard/issues_spec.rb
+++ b/spec/features/dashboard/issues_spec.rb
@@ -80,6 +80,8 @@ RSpec.describe 'Dashboard Issues', feature: true do
end
it 'shows the new issue page', js: true do
+ original_defaults = Gitlab::Application.routes.default_url_options
+
Gitlab::Application.routes.default_url_options = {
host: Capybara.current_session.server.host,
port: Capybara.current_session.server.port,
@@ -95,6 +97,8 @@ RSpec.describe 'Dashboard Issues', feature: true do
page.within('#content-body') do
expect(page).to have_selector('.issue-form')
end
+
+ Gitlab::Application.routes.default_url_options = original_defaults
end
end
end