lib/rubocop/cop/rspec/verbose_include_metadata.rb in gitlab-styles-8.0.0 vs lib/rubocop/cop/rspec/verbose_include_metadata.rb in gitlab-styles-9.0.0
- old
+ new
@@ -21,16 +21,18 @@
MSG = 'Use `%s` instead of `%s`.'
SELECTORS = %i[describe context feature example_group it specify example scenario its].freeze
+ # @!method include_metadata(node)
def_node_matcher :include_metadata, <<-PATTERN
(send {(const nil? :RSpec) nil?} {#{SELECTORS.map(&:inspect).join(' ')}}
!const
...
(hash $...))
PATTERN
+ # @!method invalid_metadata?(node)
def_node_matcher :invalid_metadata?, <<-PATTERN
(pair
(sym $...)
(true))
PATTERN