lib/rubocop/cop/rspec/receive_counts.rb in rubocop-rspec-2.12.1 vs lib/rubocop/cop/rspec/receive_counts.rb in rubocop-rspec-2.13.0

- old
+ new

@@ -4,25 +4,24 @@ module Cop module RSpec # Check for `once` and `twice` receive counts matchers usage. # # @example + # # bad + # expect(foo).to receive(:bar).exactly(1).times + # expect(foo).to receive(:bar).exactly(2).times + # expect(foo).to receive(:bar).at_least(1).times + # expect(foo).to receive(:bar).at_least(2).times + # expect(foo).to receive(:bar).at_most(1).times + # expect(foo).to receive(:bar).at_most(2).times # - # # bad - # expect(foo).to receive(:bar).exactly(1).times - # expect(foo).to receive(:bar).exactly(2).times - # expect(foo).to receive(:bar).at_least(1).times - # expect(foo).to receive(:bar).at_least(2).times - # expect(foo).to receive(:bar).at_most(1).times - # expect(foo).to receive(:bar).at_most(2).times - # - # # good - # expect(foo).to receive(:bar).once - # expect(foo).to receive(:bar).twice - # expect(foo).to receive(:bar).at_least(:once) - # expect(foo).to receive(:bar).at_least(:twice) - # expect(foo).to receive(:bar).at_most(:once) - # expect(foo).to receive(:bar).at_most(:twice).times + # # good + # expect(foo).to receive(:bar).once + # expect(foo).to receive(:bar).twice + # expect(foo).to receive(:bar).at_least(:once) + # expect(foo).to receive(:bar).at_least(:twice) + # expect(foo).to receive(:bar).at_most(:once) + # expect(foo).to receive(:bar).at_most(:twice).times # class ReceiveCounts < Base extend AutoCorrector MSG = 'Use `%<alternative>s` instead of `%<original>s`.'