Originate/end_state — pull request #5 by brianvh (2014-06-03 17:33:15+00:00)
Title: Add StateMachine#current_state? predicate method.

Need to return early from StateMachine#method_missing if we're performing a
state predicate check. Originally, the check happened after performing the
event lookup, but this would prevent predicate checks, if the state matched
an event and that even couldn't transition.

This commit fixes this problem and includes a regression unit spec.