          data = {'text': 'foobar' * 100}
          request = factory.put('/', data, HTTP_ACCEPT='text/html')
          response = self.view(request, pk=1).render()
          expected_error = '<span class="help-block">Ensure this field has no more than 100 characters.</span>'
          self.assertIn(expected_error, response.rendered_content.decode('utf-8'))
  
  
  class TestFKInstanceView(TestCase):
      def setUp(self):
          """
 
</s> remove         self.assertIn(expected_error, response.rendered_content.decode('utf-8'))
 </s> add         assert expected_error in response.rendered_content.decode('utf-8') </s> remove         self.assertEqual(response.status_code, status.HTTP_200_OK)
 </s> add         assert response.status_code == status.HTTP_200_OK </s> remove         self.assertEqual(response.status_code, status.HTTP_405_METHOD_NOT_ALLOWED)
        self.assertEqual(response.data, {"detail": 'Method "PUT" not allowed.'})
 </s> add         assert response.status_code == status.HTTP_405_METHOD_NOT_ALLOWED
        assert response.data == {"detail": 'Method "PUT" not allowed.'} </s> remove         self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND)
 </s> add         assert response.status_code == status.HTTP_404_NOT_FOUND </s> remove         self.assertEqual(created.content, 'foobar')
 </s> add         assert created.content == 'foobar'
        assert expected_error in response.rendered_content.decode('utf-8')
          data = {'text': 'foobar' * 100}
          request = factory.put('/', data, HTTP_ACCEPT='text/html')
          response = self.view(request, pk=1).render()
          expected_error = '<span class="help-block">Ensure this field has no more than 100 characters.</span>'
        assert expected_error in response.rendered_content.decode('utf-8')
  
  
  class TestFKInstanceView(TestCase):
      def setUp(self):
          """
keep keep keep keep replace keep keep keep keep keep
 converted test asserts of generics-test to pytest 
tests/test_generics.py