Skip to content

Commit

Permalink
Add a regression spec for Rails/HttpStatus
Browse files Browse the repository at this point in the history
Follow up #829.
  • Loading branch information
koic committed Oct 25, 2022
1 parent aa4ab80 commit c4ab8aa
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spec/rubocop/cop/rails/http_status_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@
head 550
RUBY
end

it 'does not register an offense when using numeric value for `redirect`' do
expect_no_offenses(<<~RUBY)
get '/foobar', to: redirect('/foobar/baz', status: 301)
RUBY
end
end

context 'when EnforcedStyle is `numeric`' do
Expand Down

0 comments on commit c4ab8aa

Please sign in to comment.