summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Chao <mchao@gitlab.com>2019-09-06 10:55:36 +0800
committerMark Chao <mchao@gitlab.com>2019-09-06 11:02:12 +0800
commita7eae5318fb1b26175f4c8e1bd0bacfb49c519b4 (patch)
tree8b1b5e322db558a05ad889118b6bf150f8486cd3
parent3fa16e5a7637a2c02a57584038cbc242b91c42bb (diff)
downloadgitlab-ce-ee-6481-remove-ruby-indexer.tar.gz
Test when binary is absentee-6481-remove-ruby-indexer
-rw-r--r--spec/lib/gitlab/popen_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/lib/gitlab/popen_spec.rb b/spec/lib/gitlab/popen_spec.rb
index 29afd9df74e..b398381a7e0 100644
--- a/spec/lib/gitlab/popen_spec.rb
+++ b/spec/lib/gitlab/popen_spec.rb
@@ -87,4 +87,12 @@ describe Gitlab::Popen do
it { expect(@status).to be_zero }
it { expect(@output).to eq('hello') }
end
+
+ context 'when binary is absent' do
+ it 'raises error' do
+ expect do
+ @klass.new.popen(%w[foobar])
+ end.to raise_error
+ end
+ end
end