class StateMachinesRspec::Matchers::RejectEventMatcher
Public Instance Methods
description()
click to toggle source
Calls superclass method
StateMachinesRspec::Matchers::Events::Matcher#description
# File lib/matchers/events/reject_event.rb, line 15 def description message = super message << " on #{state_machine_scope.inspect}" if state_machine_scope "reject #{message}" end
matches_events?(events)
click to toggle source
# File lib/matchers/events/reject_event.rb, line 11 def matches_events?(events) !valid_events? end
Private Instance Methods
valid_events?()
click to toggle source
# File lib/matchers/events/reject_event.rb, line 23 def valid_events? valid_events = @introspector.valid_events(@events) unless valid_events.empty? @failure_message = "Did not expect to be able to handle events: " + "#{valid_events.join(', ')} in state: " + "#{@introspector.current_state_value}" end !valid_events.empty? end