                                      if 0xD800 <= ord(ch) <= 0xDFFF):
              message = self.message.format(code_point=ord(surrogate_character))
              raise ValidationError(message, code=self.code)
  
  
  class BaseUniqueForValidator:
      message = None
      missing_message = _('This field is required.')
 
</s>
    def __eq__(self, other):
        if not isinstance(other, self.__class__):
            return NotImplemented
        return (self.message == other.message
                and self.code == other.code
                )

                                      if 0xD800 <= ord(ch) <= 0xDFFF):
              message = self.message.format(code_point=ord(surrogate_character))
              raise ValidationError(message, code=self.code)
  
    def __eq__(self, other):
        if not isinstance(other, self.__class__):
            return NotImplemented
        return (self.message == other.message
                and self.code == other.code
                )

  
  class BaseUniqueForValidator:
      message = None
      missing_message = _('This field is required.')
keep keep keep add keep keep keep keep
 Implement `__eq__` for validators (#8925)

* Implement equality operator and add test coverage

* Add documentation on implementation
rest_framework/validators.py