class Shoulda::Matchers::ActiveModel::ValidateAcceptanceOfMatcher
@private
Public Class Methods
Source
# File lib/shoulda/matchers/active_model/validate_acceptance_of_matcher.rb, line 84 def initialize(attribute) super @expected_message = :accepted end
Calls superclass method
Public Instance Methods
Source
# File lib/shoulda/matchers/active_model/validate_acceptance_of_matcher.rb, line 94 def does_not_match?(subject) super(subject) allows_value_of(false, @expected_message) end
Calls superclass method
Source
# File lib/shoulda/matchers/active_model/validate_acceptance_of_matcher.rb, line 89 def matches?(subject) super(subject) disallows_value_of(false, @expected_message) end
Calls superclass method
Source
# File lib/shoulda/matchers/active_model/validate_acceptance_of_matcher.rb, line 99 def simple_description %(validate that :#{@attribute} has been set to "1") end