def subject_should_raise(*args)
      error, message = args
      it_string = "subject should raise #{error}"
      it_string += " (#{message.inspect})" if message

      it it_string do
        expect { subject }.to raise_error error, message
      end
    end
def subject_should_raise(*args)
      error, message = args
      it_string = "subject should raise #{error}"
      it_string += " (#{message.inspect})" if message

      it it_string do
        expect { subject }.to raise_error error, message
      end
    end
Allows you to simply specify that the subject should raise an exception
 Takes no arguments or arguments of an exception class, a string, or both.

 As with RSpec's basic `to raise_error` matcher, if you don't give an error
 then the an unexpected error may cause your test to pass incorrectly

 @example Raising a string
   # Before
   subject { fail 'Test' }
   it "should raise 'Test'" do
     expect { subject }.to raise_error 'Test'
   end

   # After
   subject { fail 'Test' }
   subject_should_raise 'Test'

 @example Raising an exception class
   subject { fail ArgumentError }
   subject_should_raise ArgumentError

 @example Raising an exception class and string
   subject { fail ArgumentError, 'Test' }
   subject_should_raise ArgumentError, 'Test'