Skip to content

Update to RuboCop 1.36 and RuboCop RSpec 2.12

Sean McGivern requested to merge update-to-latest-rubocop into master

First commit message:

These are two major upgrades, described in detail at:

  1. https://docs.rubocop.org/rubocop/v1_upgrade_notes.html
  2. https://docs.rubocop.org/rubocop-rspec/upgrade_to_version_2.html

The most significant changes here are:

  1. We can now directly add let_it_be as a let equivalent for all cops in configuration, without needing to have separate cops for this. RuboCop RSpec now has all RSpec words (it, describe, etc.) in configuration.
  2. As a result of this configuration requirement for RSpec language-level information, we should no longer create cops and their configs directly, but use the provided 'config' context, along with the new 'with default RSpec/Language config' context (copied from RuboCop RSpec's own tests).
  3. Cops now inherit from RuboCop::Cop::Base.

We can also remove the EmptyLineAfterFinalLetItBe cop and just use the upstream EmptyLineAfterFinalLet cop, along with some configuration.

For #12 (closed).

Edited by Peter Leitzen

Merge request reports