          """
          The default manager, "objects", doesn't exist, because a custom one
          was provided.
          """
          self.assertRaises(AttributeError, lambda: Book.objects)
  
      def test_filtering(self):
          """
          Custom managers respond to usual filtering methods
          """
 
</s> remove         self.assertRaises(AttributeError, self.client.get, "/dates/books/2008/oct/01/nopk/")
 </s> add         with self.assertRaises(AttributeError):
            self.client.get("/dates/books/2008/oct/01/nopk/") </s> remove         self.assertRaises(TemplateDoesNotExist, self.client.get, '/render_no_template/')
 </s> add         with self.assertRaises(TemplateDoesNotExist):
            self.client.get('/render_no_template/') </s> remove         self.assertRaises(AttributeError, lambda: e.id)
 </s> add         with self.assertRaises(AttributeError):
            e.id </s> remove         self.assertRaises(TypeError, build_abc)
 </s> add         with self.assertRaises(TypeError):
            build_abc() </s> remove         self.assertRaises(TypeError, delattr, settings, '_wrapped')
 </s> add         with self.assertRaises(TypeError):
            delattr(settings, '_wrapped')
        with self.assertRaises(AttributeError):
            Book.objects
          """
          The default manager, "objects", doesn't exist, because a custom one
          was provided.
          """
        with self.assertRaises(AttributeError):
            Book.objects
  
      def test_filtering(self):
          """
          Custom managers respond to usual filtering methods
          """
keep keep keep keep replace keep keep keep keep keep
 Refs #26022 -- Used context manager version of assertRaises in tests. 
tests/custom_managers/tests.py