class RSpec::Matchers::BuiltIn::ChangeToValue
@api private Used to specify a change to a specific value (and, optionally, from a specific value).
Public Class Methods
Calls superclass method
RSpec::Matchers::BuiltIn::SpecificValuesChange::new
# File rspec-expectations/lib/rspec/matchers/built_in/change.rb, line 304 def initialize(change_details, expected_after) @description_suffix = nil super(change_details, MATCH_ANYTHING, expected_after) end
Public Instance Methods
@private
# File rspec-expectations/lib/rspec/matchers/built_in/change.rb, line 318 def does_not_match?(_event_proc) raise NotImplementedError, "Using a negated form of the `change` matcher " \ "with `to()` is not supported." end
@api public Specifies the original value.
# File rspec-expectations/lib/rspec/matchers/built_in/change.rb, line 311 def from(value) @expected_before = value @description_suffix = " from #{description_of value}" self end