Closed
Description
When travel_to
is used with a block (e.g. in an around
hook), the block is being removed from the auto-corrected code, despite freeze_time
also accepting a block
Original code:
around do |example|
travel_to(Time.current, &example)
end
Expected behavior
Correct to
around do |example|
freeze_time(&example)
end
Actual behavior
around do |example|
freeze_time
end
RuboCop version
$ [bundle exec] rubocop -V
1.36.0 (using Parser 3.1.2.1, rubocop-ast 1.21.0, running on ruby 3.1.2) [arm64-darwin21]
- rubocop-rails 2.16.0
Activity