code: def test_custom_cv(self):
      x = np.array(
          [
              ["a", "b", "c"],
              ["a", "b", "c"],
              ["a", "b", "c"],
              ["a", "b", "c"],
              ["b", "b", "c"],
              ["b", "b", "c"],
              ["b", "b", "b"],
              ["b", "b", "b"],
              ["b", "b", "b"],
              ["b", "b", "b"],
              ["a", "b", "a"],
              ["a", "b", "a"],
          ]
      )
      groups = [1, 2, 3, 1, 2, 3, 1, 2, 3, 1, 2, 3]
      y = [1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3]
      gkfold = GroupKFold(n_splits=3)
      wrapper = NestedCVWrapper(encoders.TargetEncoder(), cv=gkfold)
      result_train, result_valid = wrapper.fit_transform(
          x, y, X_test=x, groups=groups
      )
  
      # We would expect result_train != result_valid since result_train has been generated using nested
      # folds and result_valid is generated by fitting the encoder on all of the x & y daya
      self.assertFalse(np.allclose(result_train, result_valid))
  
file_path: category_encoders/tests/test_wrapper.py
imports: import numpy
  import pandas
  from unittest import TestCase
  from sklearn.model_selection import GroupKFold
  import category_encoders
  import tests.helpers
  from category_encoders.wrapper import PolynomialWrapper, NestedCVWrapper
label_desc: Use image node_id 2 for calling the TestNestedCVWrapper obj's underlying member method code with example usage: obj.test_custom_cv() without return types