code: def test_spca_max_iter_None_deprecation():
      """Check that we raise a warning for the deprecation of `max_iter=None`."""
      rng = np.random.RandomState(0)
      n_samples, n_features = 12, 10
      X = rng.randn(n_samples, n_features)
  
      warn_msg = "`max_iter=None` is deprecated in version 1.4 and will be removed"
      with pytest.warns(FutureWarning, match=warn_msg):
          MiniBatchSparsePCA(max_iter=None).fit(X)
  
imports: import sys
  import numpy
  import pytest
  from numpy.testing import assert_array_equal
  from sklearn.decomposition import PCA, MiniBatchSparsePCA, SparsePCA
  from sklearn.utils import check_random_state
  from sklearn.utils._testing import assert_allclose, assert_array_almost_equal, if_safe_multiprocessing_with_blas
label_desc: Use image node_id 16 for calling a global function with example usage: test_spca_max_iter_None_deprecation() without return types