code: def test_defaultrecursion(self):
      enc = RecursiveJSONEncoder()
      self.assertEqual(enc.encode(JSONTestObject), '"JSONTestObject"')
      enc.recurse = True
      try:
          enc.encode(JSONTestObject)
      except ValueError:
          pass
      else:
          self.fail("didn't raise ValueError on default recursion")
  
file_path: catboost/contrib/python/simplejson/py3/simplejson/tests/test_recursion.py
imports: from unittest import TestCase
  import simplejson
label_desc: Use image node_id 3 for calling the TestRecursion obj's underlying member method code with example usage: obj.test_defaultrecursion() without return types