Add some unit tests for ErrorReporter.