method
matches?
matches?(target, &block)
public
Hide source
# File lib/spec/matchers/change.rb, line 12 def matches?(target, &block) if block raise MatcherError.new("block passed to should or should_not change must use {} instead of do/end\n" ) end @target = target execute_change return false if @from && (@from != @before) return false if @to && (@to != @after) return (@before + @amount == @after) if @amount return ((@after - @before) >= @minimum) if @minimum return ((@after - @before) <= @maximum) if @maximum return @before != @after end