lib/rubocop/rspec/hook.rb in rubocop-rspec-1.43.2 vs lib/rubocop/rspec/hook.rb in rubocop-rspec-1.44.0
- old
+ new
@@ -4,14 +4,10 @@
module RSpec
# Wrapper for RSpec hook
class Hook < Concept
def_node_matcher :extract_metadata, <<~PATTERN
(block
- {
- (send _ _ #valid_scope? $...)
- (send _ _ $...)
- }
- ...
+ (send _ _ #valid_scope? ? $...) ...
)
PATTERN
def name
node.method_name