Skip to content

Commit fb29497

Browse files
committed
Fix indentation
1 parent 77a21ee commit fb29497

File tree

1 file changed

+24
-24
lines changed

1 file changed

+24
-24
lines changed

spec/rack/reverse_proxy_spec.rb

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -38,23 +38,23 @@ def app
3838
last_response.body.should == "Proxied App2"
3939
end
4040

41-
it "the response header should never contain Status" do
42-
stub_request(:any, 'example.com/test/stuff').to_return(:headers => {'Status' => '200 OK'})
43-
get '/test/stuff'
44-
last_response.headers['Status'].should == nil
45-
end
46-
47-
it "the response header should never transfer-encoding" do
48-
stub_request(:any, 'example.com/test/stuff').to_return(:headers => {'transfer-encoding' => 'Chunked'})
49-
get '/test/stuff'
50-
last_response.headers['transfer-encoding'].should == nil
51-
end
52-
53-
it "should set the Host header" do
54-
stub_request(:any, 'example.com/test/stuff')
55-
get '/test/stuff'
56-
a_request(:get, 'http://example.com/test/stuff').with(:headers => {"Host" => "example.com"}).should have_been_made
57-
end
41+
it "the response header should never contain Status" do
42+
stub_request(:any, 'example.com/test/stuff').to_return(:headers => {'Status' => '200 OK'})
43+
get '/test/stuff'
44+
last_response.headers['Status'].should == nil
45+
end
46+
47+
it "the response header should never transfer-encoding" do
48+
stub_request(:any, 'example.com/test/stuff').to_return(:headers => {'transfer-encoding' => 'Chunked'})
49+
get '/test/stuff'
50+
last_response.headers['transfer-encoding'].should == nil
51+
end
52+
53+
it "should set the Host header" do
54+
stub_request(:any, 'example.com/test/stuff')
55+
get '/test/stuff'
56+
a_request(:get, 'http://example.com/test/stuff').with(:headers => {"Host" => "example.com"}).should have_been_made
57+
end
5858

5959
describe "with preserve host turned off" do
6060
def app
@@ -108,9 +108,9 @@ def app
108108
end
109109

110110
it "should throw an exception" do
111-
stub_request(:get, 'http://example1.com/test').to_return({:body => "Proxied App"})
112-
get '/test'
113-
last_response.body.should == "Proxied App"
111+
stub_request(:get, 'http://example1.com/test').to_return({:body => "Proxied App"})
112+
get '/test'
113+
last_response.body.should == "Proxied App"
114114
end
115115
end
116116

@@ -128,20 +128,20 @@ def app
128128
end
129129
end
130130

131-
describe "with a https route" do
131+
describe "with a https route" do
132132
def app
133133
Rack::ReverseProxy.new(dummy_app) do
134134
reverse_proxy '/test', 'https://example.com'
135135
end
136136
end
137137

138-
it "should make a secure request" do
138+
it "should make a secure request" do
139139
stub_request(:get, 'https://example.com/test/stuff').to_return({:body => "Proxied Secure App"})
140140
get '/test/stuff'
141141
last_response.body.should == "Proxied Secure App"
142-
end
142+
end
143143

144-
end
144+
end
145145

146146
describe "with a route as a string" do
147147
def app

0 commit comments

Comments
 (0)