Skip to content

Commit f43e09a

Browse files
codealchemyPatrickTulskie
authored andcommitted
Fix undef header method failures
``` NoMethodError: undefined method `header' for #<Rack::MockResponse:0x00005611e9cbc950> Did you mean? headers ``` `#header` was dropped in the Rack 3.1 release (https://github.com/rack/rack/blob/main/CHANGELOG.md#removed-1), while the `#location` helper has been around since 2.x (rack/rack@5e0b0a3)
1 parent 0bf8a98 commit f43e09a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/resque-web_test.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ module Test
307307
test 'redirects to overview' do
308308
post '/delayed/cancel_now'
309309
assert last_response.status == 302
310-
assert last_response.header['Location'].include? '/delayed'
310+
assert last_response.location.include? '/delayed'
311311
end
312312
end
313313

@@ -316,7 +316,7 @@ module Test
316316

317317
test 'redirects to delayed' do
318318
assert last_response.status == 302
319-
assert last_response.header['Location'].include? '/delayed'
319+
assert last_response.location.include? '/delayed'
320320
end
321321
end
322322

0 commit comments

Comments
 (0)