mirror of
https://github.com/discourse/discourse.git
synced 2025-06-03 14:04:36 +08:00
Revert "DEV: Upgrade Rails to version 7.1 (#27539)"
This reverts commit ca4af53be8cb91aa3fe48ecbcf5a578189be32fa.
This commit is contained in:

committed by
Loïc Guitaut

parent
60d5170587
commit
160011793a
@ -14,7 +14,7 @@ RSpec.describe Hijack do
|
||||
self.request = ActionController::TestRequest.new(env, nil, nil)
|
||||
|
||||
# we need this for the 418
|
||||
set_response!(ActionDispatch::Response.new)
|
||||
self.response = ActionDispatch::Response.new
|
||||
end
|
||||
|
||||
def hijack_test(&blk)
|
||||
@ -22,10 +22,12 @@ RSpec.describe Hijack do
|
||||
end
|
||||
end
|
||||
|
||||
let(:tester) { Hijack::Tester.new }
|
||||
let :tester do
|
||||
Hijack::Tester.new
|
||||
end
|
||||
|
||||
describe "Request Tracker integration" do
|
||||
let(:logger) do
|
||||
let :logger do
|
||||
lambda do |env, data|
|
||||
@calls += 1
|
||||
@status = data[:status]
|
||||
@ -179,7 +181,7 @@ RSpec.describe Hijack do
|
||||
end
|
||||
|
||||
result =
|
||||
"HTTP/1.1 302 Found\r\nLocation: http://awesome.com\r\nContent-Type: text/html; charset=utf-8\r\nContent-Length: 0\r\nConnection: close\r\nX-Runtime: 1.000000\r\n\r\n"
|
||||
"HTTP/1.1 302 Found\r\nLocation: http://awesome.com\r\nContent-Type: text/html; charset=utf-8\r\nContent-Length: 84\r\nConnection: close\r\nX-Runtime: 1.000000\r\n\r\n<html><body>You are being <a href=\"http://awesome.com\">redirected</a>.</body></html>"
|
||||
expect(tester.io.string).to eq(result)
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user