Class: Spec::Expectations::Should::NotChange

Inherits:
Change show all
Defined in:
lib/spec/expectations/should/change.rb

Instance Method Summary collapse

Methods inherited from Change

#by, #execute_change, #from, #initialize, #message, #to

Methods inherited from Base

#==, #=~, #default_message, #fail_with_message, #find_supported_sym

Constructor Details

This class inherits a constructor from Spec::Expectations::Should::Change

Instance Method Details

#evaluate_changeObject



59
60
61
62
63
# File 'lib/spec/expectations/should/change.rb', line 59

def evaluate_change
  if @before_change != @after_change
    fail_with_message "#{@message} should not have changed, but did change from #{@before_change.inspect} to #{@after_change.inspect}"
  end
end