Skip to content

Cleanup removed files from RuboCop TODOs and rspec_order_todo.yml

Peter Leitzen requested to merge pl-cleanup-removed-files into master

What does this MR do and why?

This commit removes excludes from RuboCop TODOs and rspec_order_todo.yml for removed/non-existent files.

Done via https://gitlab.com/-/snippets/2482940.

Follow-up of !118039 (merged).

How to set up and validate locally

# Check diff
git diff HEAD~

# Collect files removed
git diff HEAD~ | rg -r '$1' -o '^-\s+- (\S+)' | sort | uniq

# Check if they still exist via `stat`
git diff HEAD~ | rg -r '$1' -o '^-\s+- (\S+)'  | sort | uniq | xargs stat -c "%n" {} 2>/dev/null
# No output

# Verify by touching a removed file
touch spec/views/projects/merge_requests/show.html.haml_spec.rb

# Run again
git diff HEAD~ | rg -r '$1' -o '^-\s+- (\S+)'  | sort | uniq | xargs stat -c "%n" {} 2>/dev/null
spec/views/projects/merge_requests/show.html.haml_spec.rb

Git stats

 .rubocop_todo/capybara/visibility_matcher.yml      |   1 -
 .rubocop_todo/factory_bot/create_list.yml          |   1 -
 .rubocop_todo/fips/sha1.yml                        |   3 -
 .rubocop_todo/gitlab/namespaced_class.yml          |  13 -
 .rubocop_todo/gitlab/no_code_coverage_comment.yml  |   2 -
 .rubocop_todo/gitlab/service_response.yml          |   1 -
 .rubocop_todo/gitlab/strong_memoize_attr.yml       |  11 -
 .rubocop_todo/graphql/descriptions.yml             |   1 -
 .../graphql/resource_not_available_error.yml       |   1 -
 .rubocop_todo/layout/argument_alignment.yml        |  41 ---
 .rubocop_todo/layout/array_alignment.yml           |   6 -
 .../layout/empty_line_after_magic_comment.yml      |  21 --
 .../layout/first_array_element_indentation.yml     |   3 -
 .../layout/first_hash_element_indentation.yml      |  11 -
 .rubocop_todo/layout/hash_alignment.yml            |   2 -
 .../layout/line_continuation_leading_space.yml     |   2 -
 .rubocop_todo/layout/line_continuation_spacing.yml |  11 -
 .../line_end_string_concatenation_indentation.yml  |  11 -
 .rubocop_todo/layout/line_length.yml               | 128 --------
 .rubocop_todo/layout/parameter_alignment.yml       |   1 -
 .rubocop_todo/layout/space_in_lambda_literal.yml   |   3 -
 .rubocop_todo/layout/space_inside_parens.yml       |   3 -
 .rubocop_todo/layout/trailing_whitespace.yml       |   1 -
 .../lint/ambiguous_operator_precedence.yml         |   3 -
 .rubocop_todo/lint/ambiguous_regexp_literal.yml    |   1 -
 .rubocop_todo/lint/assignment_in_condition.yml     |   6 -
 .../lint/constant_definition_in_block.yml          |   1 -
 .rubocop_todo/lint/empty_block.yml                 |   5 -
 .../lint/missing_cop_enable_directive.yml          |   4 -
 .../lint/no_return_in_begin_end_blocks.yml         |   1 -
 .rubocop_todo/lint/non_atomic_file_operation.yml   |   3 -
 .rubocop_todo/lint/or_assignment_to_constant.yml   |   1 -
 .../lint/redundant_cop_disable_directive.yml       |   4 -
 .rubocop_todo/lint/symbol_conversion.yml           |   6 -
 .rubocop_todo/lint/unused_block_argument.yml       |  13 -
 .rubocop_todo/lint/unused_method_argument.yml      |  16 -
 .rubocop_todo/metrics/abc_size.yml                 |   1 -
 .rubocop_todo/metrics/parameter_lists.yml          |   1 -
 .../migration/background_migration_base_class.yml  |  12 -
 .../migration/background_migration_record.yml      |   6 -
 .rubocop_todo/migration/background_migrations.yml  |   4 -
 .rubocop_todo/naming/heredoc_delimiter_naming.yml  |   2 -
 .../performance/method_object_as_block.yml         |   4 -
 .rubocop_todo/performance/regexp_match.yml         |   2 -
 .rubocop_todo/rails/file_path.yml                  |   6 -
 .rubocop_todo/rails/inverse_of.yml                 |   1 -
 .../rails/lexically_scoped_action_filter.yml       |   1 -
 .rubocop_todo/rails/negate_include.yml             |   1 -
 .rubocop_todo/rails/output_safety.yml              |   3 -
 .rubocop_todo/rails/pluck.yml                      |   5 -
 .rubocop_todo/rails/time_zone.yml                  |  15 -
 .rubocop_todo/rspec/any_instance_of.yml            |  16 -
 .../rspec/avoid_conditional_statements.yml         |   1 -
 .rubocop_todo/rspec/before_all_role_assignment.yml |  40 ---
 .rubocop_todo/rspec/context_wording.yml            |  79 -----
 .rubocop_todo/rspec/empty_line_after_hook.yml      |   2 -
 .rubocop_todo/rspec/expect_change.yml              |  32 --
 .rubocop_todo/rspec/expect_in_hook.yml             |   8 -
 .rubocop_todo/rspec/factory_bot/avoid_create.yml   |   9 -
 .rubocop_todo/rspec/feature_category.yml           | 137 --------
 .rubocop_todo/rspec/hooks_before_examples.yml      |  12 -
 .rubocop_todo/rspec/instance_variable.yml          |  11 -
 .rubocop_todo/rspec/multiple_memoized_helpers.yml  |   1 -
 .../rspec/repeated_example_group_description.yml   |   4 -
 .rubocop_todo/rspec/return_from_stub.yml           |  17 -
 .rubocop_todo/rspec/scattered_let.yml              |  10 -
 .rubocop_todo/rspec/variable_definition.yml        |   1 -
 .rubocop_todo/rspec/verified_doubles.yml           |  27 --
 .../worker_data_consistency.yml                    |  14 -
 .rubocop_todo/style/accessor_grouping.yml          |   2 -
 .rubocop_todo/style/class_and_module_children.yml  |  11 -
 .rubocop_todo/style/empty_else.yml                 |   1 -
 .rubocop_todo/style/empty_method.yml               |   4 -
 .rubocop_todo/style/explicit_block_argument.yml    |   3 -
 .rubocop_todo/style/format_string.yml              |  11 -
 .rubocop_todo/style/guard_clause.yml               |   8 -
 .rubocop_todo/style/hash_as_last_array_item.yml    |   2 -
 .rubocop_todo/style/hash_each_methods.yml          |   2 -
 .rubocop_todo/style/if_unless_modifier.yml         |  22 --
 .rubocop_todo/style/lambda.yml                     |   1 -
 .rubocop_todo/style/numeric_literal_prefix.yml     |   4 -
 .rubocop_todo/style/redundant_interpolation.yml    |   2 -
 .rubocop_todo/style/redundant_regexp_escape.yml    |   5 -
 .rubocop_todo/style/redundant_self.yml             |   5 -
 .rubocop_todo/style/sole_nested_conditional.yml    |   2 -
 .rubocop_todo/style/string_concatenation.yml       |   6 -
 .rubocop_todo/style/symbol_proc.yml                |   9 -
 spec/support/rspec_order_todo.yml                  | 358 ---------------------
 88 files changed, 1285 deletions(-)

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Peter Leitzen

Merge request reports