  class ModelValidationTest(TestCase):
      def test_pk_validation(self):
          NonAutoPK.objects.create(name="one")
          again = NonAutoPK(name="one")
          self.assertRaises(ValidationError, again.validate_unique)
  
  
  class EvaluateMethodTest(TestCase):
      """
      Regression test for #13640: cannot filter by objects with 'evaluate' attr
 
</s> remove         self.assertRaises(ValidationError, dm.full_clean)
 </s> add         with self.assertRaises(ValidationError):
            dm.full_clean() </s> remove         self.assertRaises(TypeError, build_abc)
 </s> add         with self.assertRaises(TypeError):
            build_abc() </s> remove         self.assertRaises(ValidationError, f.clean, "", None)
 </s> add         with self.assertRaises(ValidationError):
            f.clean("", None) </s> remove         self.assertRaises(TypeError, build_no_base_classes)
 </s> add         with self.assertRaises(TypeError):
            build_no_base_classes() </s> remove         self.assertRaises(ValidationError, site.full_clean)
 </s> add         with self.assertRaises(ValidationError):
            site.full_clean()
        with self.assertRaises(ValidationError):
            again.validate_unique()
  class ModelValidationTest(TestCase):
      def test_pk_validation(self):
          NonAutoPK.objects.create(name="one")
          again = NonAutoPK(name="one")
        with self.assertRaises(ValidationError):
            again.validate_unique()
  
  
  class EvaluateMethodTest(TestCase):
      """
      Regression test for #13640: cannot filter by objects with 'evaluate' attr
keep keep keep keep replace keep keep keep keep keep
 Refs #26022 -- Used context manager version of assertRaises in tests. 
tests/model_regress/tests.py