summaryrefslogtreecommitdiff
path: root/lib/tasks
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-04-15 06:09:30 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2021-04-15 06:09:30 +0000
commit17e561ffb82d134ccdee8dfb505d9cba7c311a4c (patch)
treed54b7d229b058a4080e1ae1d6d2d6290972b453d /lib/tasks
parent1edce674dc65d54891f9a56dde344ae737c31313 (diff)
downloadgitlab-ce-17e561ffb82d134ccdee8dfb505d9cba7c311a4c.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/tasks')
-rw-r--r--lib/tasks/spec.rake10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/tasks/spec.rake b/lib/tasks/spec.rake
index 3572fd0d080..5eed5d4dce4 100644
--- a/lib/tasks/spec.rake
+++ b/lib/tasks/spec.rake
@@ -2,6 +2,8 @@
return if Rails.env.production?
+require_relative '../../tooling/merge_request_rspec_failure_rake_task'
+
namespace :spec do
desc 'GitLab | RSpec | Run unit tests'
RSpec::Core::RakeTask.new(:unit, :rspec_opts) do |t, args|
@@ -24,11 +26,19 @@ namespace :spec do
t.rspec_opts = args[:rspec_opts]
end
+ desc 'GitLab | RSpec | Run merge request RSpec failures'
+ Tooling::MergeRequestRspecFailureRakeTask.new(:merge_request_rspec_failure, :rspec_opts) do |t, args|
+ t.pattern = t.rspec_failures_on_merge_request
+ t.rspec_opts = args[:rspec_opts]
+ end
+
desc 'Run the code examples in spec/requests/api'
RSpec::Core::RakeTask.new(:api) do |t|
t.pattern = 'spec/requests/api/**/*_spec.rb'
end
+ private
+
def require_test_level
require_relative '../../tooling/quality/test_level'
end