Lines Matching full:to

2 # Licensed to the Apache Software Foundation (ASF) under one
6 # to you under the Apache License, Version 2.0 (the
12 # Unless required by applicable law or agreed to in writing,
26 @client = Thrift::HTTPClientTransport.new("http://my.domain.com/path/to/service?param=value")
30 @client.to_s == "http://my.domain.com/path/to/service?param=value"
34 expect(@client).to be_open
36 expect(@client).to be_open
42 expect(Net::HTTP).to receive(:new).with("my.domain.com", 80) do
44 expect(http).to receive(:use_ssl=).with(false)
45 …expect(http).to receive(:post).with("/path/to/service?param=value", "a test frame", {"Content-Type…
47 expect(response).to receive(:body).and_return "data"
48 expect(response).to receive(:code).and_return "200"
54 expect(@client.read(10)).to eq("data")
63 expect(Net::HTTP).to receive(:new).with("my.domain.com", 80) do
65 expect(http).to receive(:use_ssl=).with(false)
66 expect(http).to receive(:post).with("/path/to/service?param=value", "test", headers) do
68 expect(response).to receive(:body).and_return "data"
69 expect(response).to receive(:code).and_return "200"
80 expect(Net::HTTP).to receive(:new).with("my.domain.com", 80) do
82 expect(http).to receive(:use_ssl=).with(false)
83 …expect(http).to receive(:post).with("/path/to/service?param=value", "test", {"Content-Type"=>"appl…
88 expect(@client.instance_variable_get(:@outbuf)).to eq(Thrift::Bytes.empty_byte_buffer)
94 expect(Net::HTTP).to receive(:new).with("my.domain.com", 80) do
96 expect(http).to receive(:use_ssl=).with(false)
97 …expect(http).to receive(:post).with("/path/to/service?param=value", "test", {"Content-Type"=>"appl…
100 expect(response).to receive(:code).at_least(:once).and_return "503"
106 expect { @client.flush }.to raise_error(Thrift::TransportException)
113 @service_path = "/path/to/service?param=value"
122 expect(Net::HTTP).to receive(:new).with("my.domain.com", 443) do
124 expect(http).to receive(:use_ssl=).with(true)
125 expect(http).to receive(:verify_mode=).with(OpenSSL::SSL::VERIFY_PEER)
126 expect(http).to receive(:post).with(@service_path, "test",
129 expect(response).to receive(:body).and_return "data"
130 expect(response).to receive(:code).and_return "200"
136 expect(client.read(4)).to eq("data")
144 expect(Net::HTTP).to receive(:new).with("my.domain.com", 443) do
146 expect(http).to receive(:use_ssl=).with(true)
147 expect(http).to receive(:verify_mode=).with(OpenSSL::SSL::VERIFY_NONE)
148 expect(http).to receive(:post).with(@service_path, "test",
151 expect(response).to receive(:body).and_return "data"
152 expect(response).to receive(:code).and_return "200"
158 expect(client.read(4)).to eq("data")