contains the syntax for building up an expectation This is shared between the ExpecationBuilder and the Expectation
indicates whether this expectation should match with any arguments or only for the specified arguments
# File lib/caricature/expectation.rb, line 71 def any_args? @any_args end
tell the expectation it needs to raise an error with the specified arguments
# File lib/caricature/expectation.rb, line 54 def raise(*args) @error_args = args self end
tell the expectation it nees to return this value or the value returned by the block you provide to this method.
# File lib/caricature/expectation.rb, line 47 def return(value=nil) @return_value = value @return_value ||= yield if block_given? self end
tell the expectation it needs to call the super after the expecation execution
# File lib/caricature/expectation.rb, line 65 def super_after @super = :after end
tell the expecation it needs to call the super before the expectation exectution
# File lib/caricature/expectation.rb, line 60 def super_before @super = :before end
tell the expection which arguments it needs to respond to there is a magic argument here any which configures the expectation to respond to any arguments
# File lib/caricature/expectation.rb, line 39 def with(*args) @any_args = false unless args.first == :any @args = args self end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.