      ForeignKeyTarget, NestedForeignKeySource, NullableForeignKeySource
  )
  from .utils import MockObject
  
  try:
      from collections import ChainMap
  except ImportError:
      ChainMap = False
  
  
  # Test serializer fields imports.
  # -------------------------------
  
  class TestFieldImports:
 
</s> remove from rest_framework.compat import Mapping, unicode_repr
 </s> add from rest_framework.compat import Mapping </s> remove import unittest
 </s> add from collections import ChainMap </s> remove try:
    from unittest import mock
except ImportError:
    mock = None

 </s> add  </s> remove from __future__ import unicode_literals

 </s> add  </s> remove             field.run_validation(u'slug-99-\u0420')
 </s> add             field.run_validation('slug-99-\u0420')
      ForeignKeyTarget, NestedForeignKeySource, NullableForeignKeySource
  )
  from .utils import MockObject
  





  
  # Test serializer fields imports.
  # -------------------------------
  
  class TestFieldImports:
keep keep keep keep replace replace replace replace replace keep keep keep keep keep
 Dropped Python 2 compatibility. (#6615)

Thanks to Jon Dufresne (@jdufresne) for review.

Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>
Co-authored-by: Rizwan Mansuri <Rizwan@webbyfox.com> 
tests/test_serializer.py