diff --git a/Library/Homebrew/rubocops/components_order.rb b/Library/Homebrew/rubocops/components_order.rb index 84dba9a9451a774a0ad4a8ba28cd818a298f10f2..434e52579b69c84494cef4d177665ab6773840f1 100644 --- a/Library/Homebrew/rubocops/components_order.rb +++ b/Library/Homebrew/rubocops/components_order.rb @@ -11,11 +11,6 @@ module RuboCop # - `component_precedence_list` has component hierarchy in a nested list # where each sub array contains components' details which are at same precedence level class ComponentsOrder < FormulaCop - # `aspell`: options and resources should be grouped by language - COMPONENT_ALLOWLIST = %w[ - aspell - ].freeze - def audit_formula(_node, _class_node, _parent_class_node, body_node) component_precedence_list = [ [{ name: :include, type: :method_call }], @@ -234,7 +229,7 @@ module RuboCop # Method to format message for reporting component precedence violations. def component_problem(c1, c2) - return if COMPONENT_ALLOWLIST.include?(@formula_name) + return if tap_style_exception? :components_order_exceptions problem "`#{format_component(c1)}` (line #{line_number(c1)}) " \ "should be put before `#{format_component(c2)}` " \ diff --git a/Library/Homebrew/test/rubocops/components_order_spec.rb b/Library/Homebrew/test/rubocops/components_order_spec.rb index 0a925d52cade42cc40bc2f8f3865aacc12650c9b..a6ae5c73c00c2db1e6157ddeb199ea012e6fb6a8 100644 --- a/Library/Homebrew/test/rubocops/components_order_spec.rb +++ b/Library/Homebrew/test/rubocops/components_order_spec.rb @@ -543,7 +543,5 @@ describe RuboCop::Cop::FormulaAudit::ComponentsOrder do end RUBY end - - include_examples "formulae exist", described_class::COMPONENT_ALLOWLIST end end