|
239 | 239 | .to_return(status: 200, body: 'foo-cached', headers: { Etag: 'foo-etag', 'Last-Modified' => 'foo-last-modified' }) |
240 | 240 |
|
241 | 241 | allow(Net::HTTP).to receive(:Proxy).and_call_original |
242 | | - expect(Net::HTTP).to receive(:start).with('foo-uri', 80, connect_timeout: 10, open_timeout: 10, read_timeout: 10) |
243 | | - .and_call_original |
| 242 | + expect(Net::HTTP).to receive(:start).with('foo-uri', 80, {}).and_call_original |
244 | 243 |
|
245 | 244 | download_cache.get(uri) {} |
246 | 245 | end |
|
251 | 250 |
|
252 | 251 | allow(ca_certs_directory).to receive(:exist?).and_return(true) |
253 | 252 | allow(Net::HTTP).to receive(:Proxy).and_call_original |
254 | | - expect(Net::HTTP).to receive(:start).with('foo-uri', 80, connect_timeout: 10, open_timeout: 10, read_timeout: 10) |
255 | | - .and_call_original |
| 253 | + expect(Net::HTTP).to receive(:start).with('foo-uri', 80, {}).and_call_original |
256 | 254 |
|
257 | 255 | download_cache.get(uri) {} |
258 | 256 | end |
|
262 | 260 | .to_return(status: 200, body: 'foo-cached', headers: { Etag: 'foo-etag', 'Last-Modified' => 'foo-last-modified' }) |
263 | 261 |
|
264 | 262 | allow(Net::HTTP).to receive(:Proxy).and_call_original |
265 | | - expect(Net::HTTP).to receive(:start) |
266 | | - .with('foo-uri', 443, connect_timeout: 10, open_timeout: 10, read_timeout: 10, use_ssl: true) |
267 | | - .and_call_original |
| 263 | + expect(Net::HTTP).to receive(:start).with('foo-uri', 443, use_ssl: true).and_call_original |
268 | 264 |
|
269 | 265 | download_cache.get(uri_secure) {} |
270 | 266 | end |
|
275 | 271 |
|
276 | 272 | allow(ca_certs_directory).to receive(:exist?).and_return(true) |
277 | 273 | allow(Net::HTTP).to receive(:Proxy).and_call_original |
278 | | - expect(Net::HTTP).to receive(:start) |
279 | | - .with('foo-uri', 443, connect_timeout: 10, open_timeout: 10, read_timeout: 10, use_ssl: true, |
280 | | - ca_file: 'test-path').and_call_original |
| 274 | + expect(Net::HTTP).to receive(:start).with('foo-uri', 443, use_ssl: true, ca_file: 'test-path').and_call_original |
281 | 275 |
|
282 | 276 | download_cache.get(uri_secure) {} |
283 | 277 | end |
|
0 commit comments