code: def test_get_params():
      b = B()
      params_a_in_b = class_inspect.get_params(A, b)
      assert params_a_in_b == dict(a=1)
      params_a_in_b = class_inspect.get_params(A, b, ignore=["a"])
      assert params_a_in_b == {}
  
file_path: nilearn/nilearn/_utils/tests/test_class_inspect.py
imports: from sklearn.base import BaseEstimator
  from nilearn._utils import class_inspect
label_desc: Use image node_id 2 for calling a global function with example usage: test_get_params() without return types