Upgrade to GitLab Styles 9
This contains upgrades RuboCop to 1.3.6 and RuboCop RSpec to 2.12.1. See gitlab-org/ruby/gems/gitlab-styles!119 (merged) for more details.
Notable changes here are:
- Cops now get their namespace from all but the last and the first two components, rather than simply the last component. See https://github.com/rubocop/rubocop/pull/8490
- There is no more TopLevelDescribe helper for Rubocop RSpec, it's now TopLevelGroup. See https://github.com/rubocop/rubocop-rspec/pull/977
- RuboCop Rails now complains if db/schema.rb doesn't contain a schema.
For existing cops in our codebase, see !97518 (merged).
This MR contains two commits in an attempt to make it easier to review:
- The initial upgrade, with deletions of
db/schema.rb
andee/db/geo/schema.rb
as these now cause a cop to error. This also setsNewCops: disable
as we should enable any of these in gitlab-styles first: gitlab-org/ruby/gems/gitlab-styles#40 is a related issue. - Run
bundle exec rake rubocop:todo:generate
on the existing cops with new offenses (bundle exec rubocop --parallel --format offenses
). See !96880 (comment 1086831683) for a partial list here.
The second commit is the one that's most likely to need to be updated as we go. The rest should be stable unless we add new cops.
Edited by Sean McGivern