Testing an Observer with RSpec using a transition

21 views
Skip to first unread message

Max Katz

unread,
Dec 14, 2012, 1:28:46 AM12/14/12
to pluginaw...@googlegroups.com
I have tested a Rails Observer before with success when using a callback like after_save. However, I need to call a method based on a transition, and RSpec can't seem to handle that. Any way around this?

Mark Ellul

unread,
Jun 3, 2013, 11:07:58 AM6/3/13
to pluginaw...@googlegroups.com
I am no expert, but couldn't you trigger the transition on a object and then check the output of the method?
Reply all
Reply to author
Forward
0 new messages