          otherwise the validation catches the lack of a required value.
          """
          f = forms.FileField(required=True)
          self.assertEqual(f.clean(False, 'initial'), 'initial')
          self.assertRaises(ValidationError, f.clean, False)
  
      def test_full_clear(self):
          """
          Integration happy-path test that a model FileField can actually be set
          and cleared via a ModelForm.
 
</s> remove         self.assertRaises(IntegrityError, a.protect.delete)
 </s> add         with self.assertRaises(IntegrityError):
            a.protect.delete() </s> remove         self.assertRaises(ValidationError, f.clean, '0', None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean('0', None) </s> remove         self.assertRaises(ValidationError, f.clean, None, None)
        self.assertRaises(ValidationError, f.clean, '', None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean(None, None)
        with self.assertRaises(ValidationError):
            f.clean('', None) </s> remove         self.assertRaises(ValidationError, f.clean, None, None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean(None, None) </s> remove         self.assertRaises(ImproperlyConfigured,
                          self.client.get,
                          '/syndication/articles/')
 </s> add         with self.assertRaises(ImproperlyConfigured):
            self.client.get('/syndication/articles/')
        with self.assertRaises(ValidationError):
            f.clean(False)
          otherwise the validation catches the lack of a required value.
          """
          f = forms.FileField(required=True)
          self.assertEqual(f.clean(False, 'initial'), 'initial')
        with self.assertRaises(ValidationError):
            f.clean(False)
  
      def test_full_clear(self):
          """
          Integration happy-path test that a model FileField can actually be set
          and cleared via a ModelForm.
keep keep keep keep replace keep keep keep keep keep
 Refs #26022 -- Used context manager version of assertRaises in tests. 
tests/model_forms/tests.py