Which RSpec matcher should you use to verify that a method raises a specific exception class?
-
A
expect { }.to raise_error(ErrorClass)
-
B
expect { }.to throw_symbol(:error)
-
C
expect { }.to trigger_exception(ErrorClass)
-
D
expect { }.to emit_error(ErrorClass)