code: def test_cv(boston_train):
      # noise feature can be important if no cv is used, but not if cv is used
      # X_train, y_train are almost empty; we're using test part of the dataset
      X_train, X_test, y_train, y_test, feat_names = _boston_with_leak(
          *boston_train, noise_ratio=0.99
      )
  
      reg = PermutationImportance(
          SVR(C=100, gamma="auto"),
          random_state=42,
          cv=None,
          n_iter=50,  # use the same number of experiments as with cv=10
      ).fit(X_test, y_test)
  
      assert reg.score(X_test, y_test) > 0
      assert reg.estimator_.score(X_test, y_test) > 0
      print(reg.score(X_test, y_test))
      imp_nocv = _assert_importances_good(reg, feat_names)
  
      # CV feature importances
      reg = PermutationImportance(
          SVR(C=100, gamma="auto"),
          random_state=42,
          cv=10,
      ).fit(X_test, y_test)
      imp_cv = _assert_importances_good(reg, feat_names)
      assert reg.score(X_test, y_test) > 0
  
      assert imp_cv["DATALEAK"] * 10 < imp_nocv["DATALEAK"]
  
imports: import pytest
  import numpy
  from sklearn.base import is_classifier, is_regressor
  from sklearn.svm import SVR, SVC
  from sklearn.ensemble import RandomForestRegressor, RandomForestClassifier
  from sklearn.model_selection import train_test_split, cross_val_score
  from sklearn.pipeline import make_pipeline
  from sklearn.feature_selection import SelectFromModel
  from sklearn.linear_model import LogisticRegression
  import eli5
  from eli5.sklearn import PermutationImportance
  from .utils import format_as_all
label_desc: Use image node_id 6 for calling a global function with example usage: test_cv(boston_train) without return types