code: def test_parallel(self):
      # smoke test for parallelisation with deferred updating
      bounds = [(0.0, 2.0), (0.0, 2.0)]
      try:
          p = multiprocessing.Pool(2)
          with DifferentialEvolutionSolver(
              rosen, bounds, updating="deferred", workers=p.map
          ) as solver:
              assert_(solver._mapwrapper.pool is not None)
              assert_(solver._updating == "deferred")
              solver.solve()
      finally:
          p.close()
  
      with DifferentialEvolutionSolver(
          rosen, bounds, updating="deferred", workers=2
      ) as solver:
          assert_(solver._mapwrapper.pool is not None)
          assert_(solver._updating == "deferred")
          solver.solve()
  
imports: import multiprocessing
  from scipy.optimize import _differentialevolution
  from scipy.optimize._differentialevolution import DifferentialEvolutionSolver
  from scipy.optimize import differential_evolution
  import numpy
  from scipy.optimize import rosen
  from numpy.testing import assert_equal, assert_allclose, assert_almost_equal, assert_string_equal, assert_
  from pytest import raises, warns
label_desc: Use image node_id 36 for calling the TestDifferentialEvolutionSolver obj's underlying member method code with example usage: obj.test_parallel() without return types