code: def default(self, o):
      if o is JSONTestObject:
          if self.recurse:
              return [JSONTestObject]
          else:
              return "JSONTestObject"
      return json.JSONEncoder.default(o)
  
file_path: catboost/contrib/python/simplejson/py2/simplejson/tests/test_recursion.py
imports: from unittest import TestCase
  import simplejson
label_desc: Use image node_id 1 for calling the RecursiveJSONEncoder obj's underlying member method code with example usage: obj.default(o) and returns: json, list, str