Add diagnostic message for failure during CLI search deploy (#29462)
This commit is contained in:
parent
c76ae7a5c0
commit
4f4132f1a1
2 changed files with 19 additions and 0 deletions
|
@ -33,6 +33,17 @@ describe Mastodon::CLI::Search do
|
|||
end
|
||||
end
|
||||
|
||||
context 'when server communication raises an error' do
|
||||
let(:options) { { reset_chewy: true } }
|
||||
|
||||
before { allow(Chewy::Stash::Specification).to receive(:reset!).and_raise(Elasticsearch::Transport::Transport::Errors::InternalServerError) }
|
||||
|
||||
it 'Exits with error message' do
|
||||
expect { subject }
|
||||
.to raise_error(Thor::Error, /issue connecting to the search/)
|
||||
end
|
||||
end
|
||||
|
||||
context 'without options' do
|
||||
before { stub_search_indexes }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue