lib/rubocop/cop/rspec/nested_groups.rb in rubocop-rspec-1.8.0 vs lib/rubocop/cop/rspec/nested_groups.rb in rubocop-rspec-1.9.0

- old
+ new

@@ -83,18 +83,14 @@ # end # end # end # class NestedGroups < Cop - include RuboCop::RSpec::SpecOnly, - RuboCop::RSpec::TopLevelDescribe, - RuboCop::RSpec::Language + include RuboCop::RSpec::TopLevelDescribe MSG = 'Maximum example group nesting exceeded'.freeze - def_node_search :find_contexts, <<-PATTERN - (block (send nil {#{ExampleGroups::ALL.to_node_pattern}} ...) (args) ...) - PATTERN + def_node_search :find_contexts, ExampleGroups::ALL.block_pattern def on_block(node) describe, = described_constant(node) return unless describe