code: def test_deprecated_argument_not_allowed_use():
      # If the argument is supposed to be inside the kwargs one needs to set the
      # arg_in_kwargs parameter. Without it it raises a TypeError.
      with pytest.raises(TypeError):
  
          @deprecated_params("height", "scale", "0.3")
          def test1(**kwargs):
              return kwargs["scale"]
  
      # Cannot replace "*args".
      with pytest.raises(TypeError):
  
          @deprecated_params("scale", "args", "0.3")
          def test2(*args):
              return args
  
      # Cannot replace "**kwargs".
      with pytest.raises(TypeError):
  
          @deprecated_params("scale", "kwargs", "0.3")
          def test3(**kwargs):
              return kwargs
  
      # wrong number of arguments
      with pytest.raises(ValueError):
  
          @deprecated_params(["a", "b", "c"], ["x", "y"], "0.3")
          def test4(**kwargs):
              return kwargs
  
file_path: dipy/dipy/utils/tests/test_deprecator.py
imports: import sys
  import warnings
  import numpy.testing
  import pytest
  import dipy
  from dipy.testing import clear_and_catch_warnings, assert_true
  from dipy.utils.deprecator import cmp_pkg_version, _add_dep_doc, _ensure_cr, deprecate_with_version, deprecated_params, ArgsDeprecationWarning, ExpiredDeprecationError
label_desc: Use image node_id 8 for calling a global function with example usage: test_deprecated_argument_not_allowed_use() and returns: kwargs, args, kwargs, kwargs