Skip to content

Commit

Permalink
[Ruby] Refactor/rubocop bump (#369)
Browse files Browse the repository at this point in the history
* Update rubocop by introducing all other sub-gems

* Regen the TODO file for new gem introduction

* Add entry in rubocop issue tracker for problem;

* Regenerate TODO with a downgraded version of rubocop and introduced subgems

* Reintroduce local override for MethodName whilst bug is still prevalent

* Partial interim update of rubocop subgems to try alleviate deprecations / warnings

* Update rubocop gems to all latest

* Final TODO regeneration - added a few more ignores whilst gems are being updated

* Add changelog for this change and the next PR

* Fix up ruby 3.2 cop offenses

* Fix up some spacing autofix cops and add note about fix for heredoc required

* AF: Layout/SpaceAfterComma

* Fix up RSpec context

* Fix up a couple of minor autofixes for the razor template that generates the parser

* Manually fix one of the parser issues
  • Loading branch information
luke-hill authored Feb 10, 2025
1 parent d93a661 commit b71dcf1
Show file tree
Hide file tree
Showing 11 changed files with 227 additions and 113 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
### Changed
- [.NET] Reduce NuGet size by only targeting .NET Standard 2.0
- [.NET] Changed some types from class to struct, removed IGherkinLine interface and changes some functions from Array to Enumerable
- [Ruby] Update minimum ruby requirement from 3.0 to 3.2
- [Ruby] Introduce rubocop subgems to facilitate optimisations
- [JavaScript] BREAKING CHANGE: Update supported Node.js versions to 18, 20, 22 and 23 ([#365](https://github.com/cucumber/gherkin/pull/365))

### Fixed
Expand Down
18 changes: 8 additions & 10 deletions ruby/.rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@ inherit_mode:
merge:
- Exclude

#require:
# - rubocop-packaging
# - rubocop-performance
# - rubocop-rails
# - rubocop-rake
# - rubocop-rspec
require:
- rubocop-packaging
- rubocop-performance
- rubocop-rake
- rubocop-rspec

AllCops:
TargetRubyVersion: 3.2
Expand All @@ -33,10 +32,9 @@ Style/RegexpLiteral:
EnforcedStyle: slashes
AllowInnerSlashes: true

## Disabled until rubocop-rspec is introduced
#RSpec/MessageSpies:
# EnforcedStyle: receive
RSpec/MessageSpies:
EnforcedStyle: receive

# Hack to make rubocop not flag these (We need to re-analyse these later on)
# Bug in rubocop auto-gen config: https://github.com/rubocop/rubocop/issues/13795
Naming/MethodName:
Enabled: false
Loading

0 comments on commit b71dcf1

Please # to comment.