# File lib/rspec/matchers/built_in/yield.rb, line 34 def yielded_once?(matcher_name) case num_yields when 1 then true when 0 then false else raise "The #{matcher_name} matcher is not designed to be used with a " + "method that yields multiple times. Use the yield_successive_args " + "matcher for that case." end end