          obj = {'foo': ['bar', 'baz']}
          renderer = JSONRenderer()
          content = renderer.render(obj, 'application/json')
          # Fix failing test case which depends on version of JSON library.
          self.assertEqual(content, _flat_repr)
  
      def test_with_content_type_args(self):
          """
          Test JSON rendering with additional content type arguments supplied.
          """
 
</s> remove     charset = 'iso-8859-1'
 </s> add     charset = 'utf-8'
    # Note that JSON encodings must be utf-8, utf-16 or utf-32.
    # See: http://www.ietf.org/rfc/rfc4627.txt </s> remove     Renderer which serializes to json.
 </s> add     Renderer which serializes to JSON.
    Applies JSON's backslash-u character escaping for non-ascii characters. </s> remove         return yaml.dump(data, stream=None, Dumper=self.encoder)
 </s> add         return yaml.dump(data, stream=None, encoding=self.charset, Dumper=self.encoder) </s> remove         return "%s(%s);" % (callback, json)
 </s> add         return callback.encode(self.charset) + b'(' + json + b');'
        self.assertEqual(content.decode('utf-8'), _flat_repr)
          obj = {'foo': ['bar', 'baz']}
          renderer = JSONRenderer()
          content = renderer.render(obj, 'application/json')
          # Fix failing test case which depends on version of JSON library.
        self.assertEqual(content.decode('utf-8'), _flat_repr)
  
      def test_with_content_type_args(self):
          """
          Test JSON rendering with additional content type arguments supplied.
          """
keep keep keep keep replace keep keep keep keep keep
 Last bits of charset sorting-out-ness 
rest_framework/tests/renderers.py