          # Similar to a regular Form class you can define custom media to be used on
          # the ModelForm.
          f = ModelFormWithMedia()
          self.assertHTMLEqual(
              six.text_type(f.media),
              '''<link href="/some/form/css" type="text/css" media="all" rel="stylesheet" />
  <script type="text/javascript" src="/some/form/javascript"></script>'''
          )
  
      def test_choices_type(self):
 
</s> remove         return "%s (%s)" % (self.revision, six.text_type(self.repository))
 </s> add         return "%s (%s)" % (self.revision, str(self.repository)) </s> remove             six.text_type(f),
 </s> add             str(f), </s> remove             six.text_type(f),
 </s> add             str(f), </s> remove         form_data['categories'] = [six.text_type(self.c1.id), six.text_type(self.c2.id)]
 </s> add         form_data['categories'] = [str(self.c1.id), str(self.c2.id)] </s> remove             # Class names must be ASCII in Python 2.x, so we forcibly coerce it
            # here to break early if there's a problem.
            to = str(to)
 </s> add 
            str(f.media),
          # Similar to a regular Form class you can define custom media to be used on
          # the ModelForm.
          f = ModelFormWithMedia()
          self.assertHTMLEqual(
            str(f.media),
              '''<link href="/some/form/css" type="text/css" media="all" rel="stylesheet" />
  <script type="text/javascript" src="/some/form/javascript"></script>'''
          )
  
      def test_choices_type(self):
keep keep keep keep replace keep keep keep keep keep
 Refs #23919 -- Removed six.<various>_types usage

Thanks Tim Graham and Simon Charette for the reviews. 
tests/model_forms/tests.py