lib/rubocop/cop/rspec/iterated_expectation.rb in rubocop-rspec-1.32.0 vs lib/rubocop/cop/rspec/iterated_expectation.rb in rubocop-rspec-1.33.0
- old
+ new
@@ -1,5 +1,7 @@
+# frozen_string_literal: true
+
module RuboCop
module Cop
module RSpec
# Check that `all` matcher is used instead of iterating over an array.
#
@@ -13,10 +15,10 @@
# it 'validates users' do
# expect([user1, user2, user3]).to all(be_valid)
# end
class IteratedExpectation < Cop
MSG = 'Prefer using the `all` matcher instead ' \
- 'of iterating over an array.'.freeze
+ 'of iterating over an array.'
def_node_matcher :each?, <<-PATTERN
(block
(send ... :each)
(args (arg $_))