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:
Diffstat (limited to 'spec/controllers/concerns')
-rw-r--r--spec/controllers/concerns/confirm_email_warning_spec.rb2
-rw-r--r--spec/controllers/concerns/graceful_timeout_handling_spec.rb2
-rw-r--r--spec/controllers/concerns/redirects_for_missing_path_on_tree_spec.rb2
-rw-r--r--spec/controllers/concerns/renders_commits_spec.rb1
4 files changed, 4 insertions, 3 deletions
diff --git a/spec/controllers/concerns/confirm_email_warning_spec.rb b/spec/controllers/concerns/confirm_email_warning_spec.rb
index 24ee6fb30d2..334c156e1ae 100644
--- a/spec/controllers/concerns/confirm_email_warning_spec.rb
+++ b/spec/controllers/concerns/confirm_email_warning_spec.rb
@@ -18,7 +18,7 @@ RSpec.describe ConfirmEmailWarning do
RSpec::Matchers.define :set_confirm_warning_for do |email|
match do |response|
- expect(response).to set_flash.now[:warning].to include("Please check your email (#{email}) to verify that you own this address and unlock the power of CI/CD.")
+ expect(controller).to set_flash.now[:warning].to include("Please check your email (#{email}) to verify that you own this address and unlock the power of CI/CD.")
end
end
diff --git a/spec/controllers/concerns/graceful_timeout_handling_spec.rb b/spec/controllers/concerns/graceful_timeout_handling_spec.rb
index cece36f06b2..e496d12856b 100644
--- a/spec/controllers/concerns/graceful_timeout_handling_spec.rb
+++ b/spec/controllers/concerns/graceful_timeout_handling_spec.rb
@@ -9,7 +9,7 @@ RSpec.describe GracefulTimeoutHandling, type: :controller do
skip_before_action :authenticate_user!
def index
- raise ActiveRecord::QueryCanceled.new
+ raise ActiveRecord::QueryCanceled
end
end
diff --git a/spec/controllers/concerns/redirects_for_missing_path_on_tree_spec.rb b/spec/controllers/concerns/redirects_for_missing_path_on_tree_spec.rb
index 5c3b6e13ee3..ccd5570f2bd 100644
--- a/spec/controllers/concerns/redirects_for_missing_path_on_tree_spec.rb
+++ b/spec/controllers/concerns/redirects_for_missing_path_on_tree_spec.rb
@@ -27,7 +27,7 @@ RSpec.describe RedirectsForMissingPathOnTree, type: :controller do
get :fake, params: { project_id: project.id, ref: 'theref', file_path: long_file_path }
expect(response).to redirect_to project_tree_path(project, 'theref')
- expect(response.flash[:notice]).to eq(expected_message)
+ expect(controller).to set_flash[:notice].to eq(expected_message)
end
end
end
diff --git a/spec/controllers/concerns/renders_commits_spec.rb b/spec/controllers/concerns/renders_commits_spec.rb
index 7b241fc29af..5c918267f50 100644
--- a/spec/controllers/concerns/renders_commits_spec.rb
+++ b/spec/controllers/concerns/renders_commits_spec.rb
@@ -66,6 +66,7 @@ RSpec.describe RendersCommits do
expect do
subject.prepare_commits_for_rendering(merge_request.commits)
+ merge_request.commits.each(&:latest_pipeline)
end.not_to exceed_all_query_limit(control.count)
end
end