Skip to content

Commit

Permalink
Add alias for legacy RSpec matcher deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
porteta committed Mar 4, 2014
1 parent b57208a commit 8524e8f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/paperclip/matchers/validate_attachment_size_matcher.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,10 @@ def failure_message
"Attachment #{@attachment_name} must be between #{@low} and #{@high} bytes"
end

def negative_failure_message
def failure_message_when_negated
"Attachment #{@attachment_name} cannot be between #{@low} and #{@high} bytes"
end
alias negative_failure_message failure_message_when_negated

def description
"validate the size of attachment #{@attachment_name}"
Expand Down

0 comments on commit 8524e8f

Please sign in to comment.