code: def test_loads():
      eq_(loads('{"a": 2}'), {"a": 2})
      with assert_raises(JSONDecodeError), swallow_logs(
          new_level=logging.WARNING
      ) as cml:
          loads('{"a": 2}x')
      assert_in("Failed to load content from", cml.out)
  
file_path: datalad/datalad/support/tests/test_json_py.py
imports: import logging
  import os.path
  from json import JSONDecodeError
  from datalad.support.json_py import dump, dump2stream, load, load_stream, loads
  from datalad.tests.utils_pytest import assert_in, assert_raises, eq_, swallow_logs, with_tempfile
label_desc: Use image node_id 3 for calling a global function with example usage: test_loads() without return types