code: def check_samplers_fit(name, sampler_orig):
      sampler = clone(sampler_orig)
      np.random.seed(42)  # Make this test reproducible
      X = np.random.random((30, 2))
      y = np.array([1] * 20 + [0] * 10)
      sampler.fit_resample(X, y)
      assert hasattr(
          sampler, "sampling_strategy_"
      ), "No fitted attribute sampling_strategy_"
  
imports: import re
  import sys
  import traceback
  import warnings
  from collections import Counter
  from functools import partial
  import numpy
  import pytest
  import sklearn
  from scipy import sparse
  from sklearn.base import clone, is_classifier, is_regressor
  from sklearn.cluster import KMeans
  from sklearn.datasets import load_iris, make_blobs, make_classification, make_multilabel_classification
  from sklearn.exceptions import SkipTestWarning
  from sklearn.preprocessing import StandardScaler, label_binarize
  from sklearn.utils._tags import _safe_tags
  from sklearn.utils._testing import SkipTest, assert_allclose, assert_array_equal, assert_raises_regex, raises, set_random_state
  from sklearn.utils.estimator_checks import _enforce_estimator_tags_y, _get_check_estimator_ids, _maybe_mark_xfail
  from sklearn.utils.fixes import parse_version
  from sklearn.utils.multiclass import type_of_target
  from imblearn.datasets import make_imbalance
  from imblearn.over_sampling.base import BaseOverSampler
  from imblearn.under_sampling.base import BaseCleaningSampler, BaseUnderSampler
  from imblearn.utils._param_validation import generate_invalid_param_val, make_constraint
label_desc: Use image node_id 10 for calling a global function with example usage: check_samplers_fit(name, sampler_orig) without return types