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/workers/gitlab_shell_worker_spec.rb')
-rw-r--r--spec/workers/gitlab_shell_worker_spec.rb31
1 files changed, 0 insertions, 31 deletions
diff --git a/spec/workers/gitlab_shell_worker_spec.rb b/spec/workers/gitlab_shell_worker_spec.rb
deleted file mode 100644
index 9fff4489667..00000000000
--- a/spec/workers/gitlab_shell_worker_spec.rb
+++ /dev/null
@@ -1,31 +0,0 @@
-# frozen_string_literal: true
-
-require 'spec_helper'
-
-RSpec.describe GitlabShellWorker, :sidekiq_inline, feature_category: :source_code_management do
- describe '#perform' do
- Gitlab::Shell::PERMITTED_ACTIONS.each do |action|
- describe "with the #{action} action" do
- it 'forwards the message to Gitlab::Shell' do
- expect_next_instance_of(Gitlab::Shell) do |instance|
- expect(instance).to respond_to(action)
- expect(instance).to receive(action).with('foo', 'bar')
- end
-
- described_class.perform_async(action, 'foo', 'bar')
- end
- end
- end
-
- describe 'all other commands' do
- it 'raises ArgumentError' do
- allow_next_instance_of(described_class) do |job_instance|
- expect(job_instance).not_to receive(:gitlab_shell)
- end
-
- expect { described_class.perform_async('foo', 'bar', 'baz') }
- .to raise_error(ArgumentError, 'foo not allowed for GitlabShellWorker')
- end
- end
- end
-end