Commit bc7fd25a authored by Terence Lee's avatar Terence Lee

use URI where possible in tests

parent f2c9a416
...@@ -97,7 +97,9 @@ RSpec.describe "Simple" do ...@@ -97,7 +97,9 @@ RSpec.describe "Simple" do
it "should redirect http to https" do it "should redirect http to https" do
response = app.get("/foo") response = app.get("/foo")
expect(response.code).to eq("301") expect(response.code).to eq("301")
expect(response['location']).to eq("https://#{AppRunner::HOST_IP}/foo") uri = URI(response['Location'])
expect(uri.scheme).to eq("https")
expect(uri.path).to eq("/foo")
end end
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment