File tree Expand file tree Collapse file tree 3 files changed +0
-9
lines changed
lib/elasticsearch/transport/transport
spec/elasticsearch/transport Expand file tree Collapse file tree 3 files changed +0
-9
lines changed Original file line number Diff line number Diff line change 18
18
module Elasticsearch
19
19
module Transport
20
20
module Transport
21
-
22
21
# Wraps the response from Elasticsearch.
23
22
#
24
23
class Response
Original file line number Diff line number Diff line change 109
109
end
110
110
111
111
context 'when `perform_request` is called without a `retry_on_failure` option value' do
112
-
113
112
before do
114
113
expect ( client . transport ) . to receive ( :get_connection ) . exactly ( 3 ) . times . and_call_original
115
114
end
122
121
end
123
122
124
123
context 'when `perform_request` is called with a `retry_on_failure` option value' do
125
-
126
124
before do
127
125
expect ( client . transport ) . to receive ( :get_connection ) . exactly ( 6 ) . times . and_call_original
128
126
end
136
134
end
137
135
138
136
context 'when the client has `retry_on_failure` set to true' do
139
-
140
137
let ( :client ) do
141
138
Elasticsearch ::Transport ::Client . new ( arguments )
142
139
end
149
146
end
150
147
151
148
context 'when `perform_request` is called without a `retry_on_failure` option value' do
152
-
153
149
before do
154
150
expect ( client . transport ) . to receive ( :get_connection ) . exactly ( 4 ) . times . and_call_original
155
151
end
162
158
end
163
159
164
160
context 'when `perform_request` is called with a `retry_on_failure` option value' do
165
-
166
161
before do
167
162
expect ( client . transport ) . to receive ( :get_connection ) . exactly ( 6 ) . times . and_call_original
168
163
end
176
171
end
177
172
178
173
context 'when the client has `retry_on_failure` set to false' do
179
-
180
174
let ( :client ) do
181
175
Elasticsearch ::Transport ::Client . new ( arguments )
182
176
end
189
183
end
190
184
191
185
context 'when `perform_request` is called without a `retry_on_failure` option value' do
192
-
193
186
before do
194
187
expect ( client . transport ) . to receive ( :get_connection ) . once . and_call_original
195
188
end
Original file line number Diff line number Diff line change 18
18
require 'spec_helper'
19
19
20
20
describe Elasticsearch ::Transport ::Client do
21
-
22
21
let ( :client ) do
23
22
described_class . new . tap do |_client |
24
23
allow ( _client ) . to receive ( :__build_connections )
You can’t perform that action at this time.
0 commit comments