      A dict-like object, that can have additional properties attached.
      """
  
      def __getstate__(self):
          """  Used by pickle (e.g., caching).
               Overriden to remove metadata from the dict, since it shouldn't be pickled
               and may in some instances be unpickleable.
          """
          # return an instance of the first dict in MRO that isn't a DictWithMetadata
          for base in self.__class__.__mro__:
              if not isinstance(base, DictWithMetadata) and isinstance(base, dict):
                  return base(self)
 
</s> remove     """ Test pickleability of the output of Serializers
 </s> add     """
    Test pickleability of the output of Serializers </s> remove         """ Test simple serializer
 </s> add         """
        Test simple serializer </s> remove         """ Test pickling a serializer whose resulting .data (a SortedDictWithMetadata) will
         have unpickleable meta data--in order to make sure metadata doesn't get pulled into the pickle.
         See DictWithMetadata.__getstate__
 </s> add         """
        Test pickling a serializer whose resulting .data (a SortedDictWithMetadata) will
        have unpickleable meta data--in order to make sure metadata doesn't get pulled into the pickle.
        See DictWithMetadata.__getstate__
        """
        Used by pickle (e.g., caching).
        Overriden to remove metadata from the dict, since it shouldn't be pickled
        and may in some instances be unpickleable.
      A dict-like object, that can have additional properties attached.
      """
  
      def __getstate__(self):
        """
        Used by pickle (e.g., caching).
        Overriden to remove metadata from the dict, since it shouldn't be pickled
        and may in some instances be unpickleable.
        """
        Used by pickle (e.g., caching).
        Overriden to remove metadata from the dict, since it shouldn't be pickled
        and may in some instances be unpickleable.
        """
        Used by pickle (e.g., caching).
        Overriden to remove metadata from the dict, since it shouldn't be pickled
        and may in some instances be unpickleable.
          """
          # return an instance of the first dict in MRO that isn't a DictWithMetadata
          for base in self.__class__.__mro__:
              if not isinstance(base, DictWithMetadata) and isinstance(base, dict):
                  return base(self)
keep keep keep keep replace replace replace keep keep keep keep keep
 cleaned up white space & docstring styling 
rest_framework/serializers.py