code: def test_basinhopping_Alpine02(minimizer_Alpine02):
      """Test basinhopping on Alpine02 function."""
      global_optimum = [7.91705268, 4.81584232]
      fglob = -6.12950
  
      kws = {"minimizer_kwargs": {"method": "L-BFGS-B"}, "seed": 7}
      out = minimizer_Alpine02.minimize(method="basinhopping", **kws)
      out_x = np.array([out.params["x0"].value, out.params["x1"].value])
  
      assert_allclose(out.residual, fglob, rtol=1e-5)
      assert_allclose(min(out_x), min(global_optimum), rtol=1e-3)
      assert_allclose(max(out_x), max(global_optimum), rtol=1e-3)
      assert out.method == "basinhopping"
  
file_path: lmfit-py/tests/test_basinhopping.py
imports: import numpy
  from numpy.testing import assert_allclose
  import pytest
  from scipy.optimize import basinhopping
  import lmfit
label_desc: Use image node_id 3 for calling a global function with example usage: test_basinhopping_Alpine02(minimizer_Alpine02) without return types