Class: ValidationErrorReporter::ProfileFormatter
- Defined in:
- lib/validation_error_reporter/profile_formatter.rb
Instance Method Summary collapse
Instance Method Details
#format(profile) ⇒ Object
4 5 6 7 8 9 10 |
# File 'lib/validation_error_reporter/profile_formatter.rb', line 4 def format(profile) return "No errors" if profile.empty? "Summary:\n" + "Model with most errors: #{dump(profile, :count)}.\n" + "Model with highest error rate: #{dump(profile, :rate)}." end |