State :exit called when all transitions fail
-
Nathaniel Bibler
- Tag changed from bug to bug, patch
I've attached a patch which adds a spec to exercise this expectation, as well as a simple fix to pass it.
-
Nathaniel Bibler
If it's any easier for you to check out, I've also got this modification on GitHub.
-
rubyist
Thanks for the patch, Nathaniel, I'll check this out today.
-Scott
-
Nathaniel Bibler
Technically, this patch may change the callback execution sequence in a way which is unexpected. While the specs do not test the order in which callbacks are executed, I imagine this may cause problems down the road.
The previous execution sequence:
- OldState.exit
- SuccessfulTransition.on_success
- NewState.enter
With the above mentioned patch, the sequence is as follows:
- SuccessfulTransition.on_success
- OldState.exit
- NewState.enter
I figured I'd mention it while I was thinking about it and it wasn't yet adopted. :-D
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
