      def testInheritance(self):
          self.assertFormfield(models.Album, 'backside_art', widgets.AdminFileWidget)
  
  
  @override_settings(PASSWORD_HASHERS=('django.contrib.auth.hashers.SHA1PasswordHasher',))
  class AdminFormfieldForDBFieldWithRequestTests(DjangoTestCase):
      fixtures = ["admin-widgets-users.xml"]
      urls = 'admin_widgets.urls'
 
</s> remove         return db_field.formfield(**kwargs)
 </s> add         form_field = db_field.formfield(**kwargs)
        if isinstance(form_field.widget, SelectMultiple) and not isinstance(form_field.widget, CheckboxSelectMultiple):
            msg = _('Hold down "Control", or "Command" on a Mac, to select more than one.')
            help_text = form_field.help_text
            form_field.help_text = string_concat(help_text, ' ', msg) if help_text else msg
        return form_field
    def test_m2m_widgets(self):
        """m2m fields help text as it applies to admin app (#9321)."""
        class AdvisorAdmin(admin.ModelAdmin):
            filter_vertical = ['companies']

        self.assertFormfield(models.Advisor, 'companies', widgets.FilteredSelectMultiple,
                             filter_vertical=['companies'])
        ma = AdvisorAdmin(models.Advisor, admin.site)
        f = ma.formfield_for_dbfield(models.Advisor._meta.get_field('companies'), request=None)
        self.assertEqual(six.text_type(f.help_text), 'Hold down "Control", or "Command" on a Mac, to select more than one.')

      def testInheritance(self):
          self.assertFormfield(models.Album, 'backside_art', widgets.AdminFileWidget)
  
    def test_m2m_widgets(self):
        """m2m fields help text as it applies to admin app (#9321)."""
        class AdvisorAdmin(admin.ModelAdmin):
            filter_vertical = ['companies']

        self.assertFormfield(models.Advisor, 'companies', widgets.FilteredSelectMultiple,
                             filter_vertical=['companies'])
        ma = AdvisorAdmin(models.Advisor, admin.site)
        f = ma.formfield_for_dbfield(models.Advisor._meta.get_field('companies'), request=None)
        self.assertEqual(six.text_type(f.help_text), 'Hold down "Control", or "Command" on a Mac, to select more than one.')

  
  @override_settings(PASSWORD_HASHERS=('django.contrib.auth.hashers.SHA1PasswordHasher',))
  class AdminFormfieldForDBFieldWithRequestTests(DjangoTestCase):
      fixtures = ["admin-widgets-users.xml"]
      urls = 'admin_widgets.urls'
keep keep add keep keep keep keep keep
 Made m2m fields form help_text munging specific to admin widgets.

Refs #9321 and follow-up to e80de93af6a0a21a9063a55c4d6d20e3927243e9. 
tests/admin_widgets/tests.py