title: How to test assm guard error with rspec?
body: <p>I have a state machine with some guards to prevent special state transitions.
  In my spec, I'm trying to expect guard violation error like this:</p>
  
  <pre><code>expect(violate_guard).to raise_exception
  </code></pre>
  
  <p>As a result, I receive correct error in my spec test:</p>
  
  <blockquote>
    <p>Failure/Error: expect(my_model.change_event).to raise_exception
         AASM::InvalidTransition:
           Event 'change_event' cannot transition from 'current_state'</p>
  </blockquote>
  
  <p>I'm wondering how should I change my spec to have a satisfied test?</p>