Rename cancellable? to cancelable? in AutoCancelPolicy
What does this MR do and why?
Renames the private predicate cancellable? to cancelable? in
Gitlab::Ci::RedundantPipelines::AutoCancelPolicy, and fixes the same
double-l spelling in nearby comments and RSpec example names.
The codebase prefers the single-l US spelling. Counting app/ and lib/:
| Pair | Count |
|---|---|
cancelable / cancellable |
209 / 6 |
canceling / cancelling |
432 / 6 |
canceled / cancelled |
1520 / 656 |
The rename also makes the predicate consistent with its public caller,
cancelable_by_newer_pipeline?.
cancellation is left as-is. The double l is correct there in both US and
UK English, so safe_cancellation: and similar are already right.
The method is private and the class has no callers yet, so this is a pure rename with no behaviour change.
app/services/ci/pipeline_creation/cancel_redundant_pipelines_service.rb
is deliberately untouched. It holds a few double-l names, but three of them
are structured log field names that external dashboards may query.
How to set up and validate locally
bundle exec rspec spec/lib/gitlab/ci/redundant_pipelines/auto_cancel_policy_spec.rb27 examples, 0 failures. reek and rubocop are clean on both files.
References
- Review comment: !257237 (comment 3899631855)
- Discussion issue: #621543
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist.