          mediatype = _MediaType('test/*; foo=bar')
          assert str(mediatype) == 'test/*; foo=bar'
  
      def test_raise_error_if_no_suitable_renderers_found(self):
          class MockRenderer(object):
              format = 'xml'
          renderers = [MockRenderer()]
          with pytest.raises(Http404):
              self.negotiator.filter_renderers(renderers, format='json')
  
 
</s> remove         request = factory.patch('/{0}'.format(obj.pk), {'number_value': 101}, format='json')
 </s> add         request = factory.patch('/{}'.format(obj.pk), {'number_value': 101}, format='json') </s> remove         request = factory.patch('/{0}'.format(obj.pk), {'number_value': 98}, format='json')
 </s> add         request = factory.patch('/{}'.format(obj.pk), {'number_value': 98}, format='json') </s> remove         request = factory.put('/{0}'.format(filtered_out_pk), data, format='json')
 </s> add         request = factory.put('/{}'.format(filtered_out_pk), data, format='json') </s> remove         assert response.content == six.b('')
 </s> add         assert response.content == b'' </s> remove         content = six.b('qwerty')
 </s> add         content = b'qwerty'
        class MockRenderer:
          mediatype = _MediaType('test/*; foo=bar')
          assert str(mediatype) == 'test/*; foo=bar'
  
      def test_raise_error_if_no_suitable_renderers_found(self):
        class MockRenderer:
              format = 'xml'
          renderers = [MockRenderer()]
          with pytest.raises(Http404):
              self.negotiator.filter_renderers(renderers, format='json')
  
keep keep keep keep replace keep keep keep keep keep
 Dropped Python 2 compatibility. (#6615)

Thanks to Jon Dufresne (@jdufresne) for review.

Co-authored-by: Asif Saif Uddin <auvipy@gmail.com>
Co-authored-by: Rizwan Mansuri <Rizwan@webbyfox.com> 
tests/test_negotiation.py