diff --git a/spec/project_spec.rb b/spec/project_spec.rb index 2b50ae0a0f..0e48135a52 100644 --- a/spec/project_spec.rb +++ b/spec/project_spec.rb @@ -251,7 +251,7 @@ end let(:existing_cop_names) do - RuboCop::Cop::Cop.registry.without_department(:Test).without_department(:Test2).cops.to_set(&:cop_name) + RuboCop::Cop::Registry.global.reject { |cop| cop.cop_name.start_with?('Test/') }.to_set(&:cop_name) end let(:legacy_cop_names) do