code: def test_boolean_constraint_deprecated_int():
      """Check that validate_params raise a deprecation message but still passes
      validation when using an int for a parameter accepting a boolean.
      """
  
      @validate_params(
          {"param": ["boolean"]}, prefer_skip_nested_validation=True
      )
      def f(param):
          pass
  
      # True/False and np.bool_(True/False) are valid params
      f(True)
      f(np.bool_(False))
  
      # an int is also valid but deprecated
      with pytest.warns(
          FutureWarning,
          match="Passing an int for a boolean parameter is deprecated",
      ):
          f(1)
  
imports: from numbers import Integral, Real
  import numpy
  import pytest
  from scipy.sparse import csr_matrix
  from sklearn.base import BaseEstimator
  from sklearn.model_selection import LeaveOneOut
  from sklearn.utils import deprecated
  from imblearn._config import config_context, get_config
  from imblearn.base import _ParamsValidationMixin
  from imblearn.utils._param_validation import HasMethods, Hidden, Interval, InvalidParameterError, MissingValues, Options, RealNotInt, StrOptions, _ArrayLikes, _Booleans, _Callables, _CVObjects, _InstancesOf, _IterablesNotString, _NoneConstraint, _PandasNAConstraint, _RandomStates, _SparseMatrices, _VerboseHelper, generate_invalid_param_val, generate_valid_param, make_constraint, validate_params
  from imblearn.utils.fixes import _fit_context
label_desc: Use image node_id 26 for calling a global function with example usage: test_boolean_constraint_deprecated_int() without return types