          self.assertEqual(datetime.date(2008, 10, 10), f.clean('2008-10-10', None))
  
      def test_boolean_field_doesnt_accept_empty_input(self):
          f = models.BooleanField()
          self.assertRaises(ValidationError, f.clean, None, None)
  
  
  class IntegerFieldTests(test.TestCase):
      model = IntegerModel
      documented_range = (-2147483648, 2147483647)
 
</s> remove         self.assertRaises(ValidationError, f.clean, None, None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean(None, 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(ValidationError, f.clean, '0', None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean('0', None) </s> remove         self.assertRaises(ValidationError, f.clean, "", None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean("", None)
        with self.assertRaises(ValidationError):
            f.clean(None, None)
          self.assertEqual(datetime.date(2008, 10, 10), f.clean('2008-10-10', None))
  
      def test_boolean_field_doesnt_accept_empty_input(self):
          f = models.BooleanField()
        with self.assertRaises(ValidationError):
            f.clean(None, None)
  
  
  class IntegerFieldTests(test.TestCase):
      model = IntegerModel
      documented_range = (-2147483648, 2147483647)
keep keep keep keep replace keep keep keep keep keep
 Refs #26022 -- Used context manager version of assertRaises in tests. 
tests/model_fields/tests.py