class_docstr: Tests keywords, multiple arguments, and non-training arguments in relevant optimizers
docstr: Test passing multiple arguments to function
docstr_tok: ["Test","passing","multiple","arguments","to","function"]
code: def test_multi_args(self, mocker, opt, opt_name, tol):
      """Test passing multiple arguments to function"""
  
      class func_wrapper:
          @staticmethod
          def func(x, y, z):
              return x[0] * y[0] + z[0]
  
      wrapper = func_wrapper()
      spy = mocker.spy(wrapper, "func")
  
      x = np.array([1.0])
      y = np.array([2.0])
      z = np.array([3.0])
  
      (x_new, y_new, z_new), cost = opt.step_and_cost(
          wrapper.func, x, y, z
      )
      self.reset(opt)
      args_called1, kwargs1 = spy.call_args_list[
          -1
      ]  # just take last call
  
      _ = opt.step(wrapper.func, x_new, y_new, z_new)
      self.reset(opt)
      args_called2, kwargs2 = spy.call_args_list[
          -1
      ]  # just take last call
  
      assert args_called1 == (x, y, z)
      assert args_called2 == (x_new, y_new, z_new)
  
      assert kwargs1 == {}
      assert kwargs2 == {}
  
      assert np.allclose(cost, wrapper.func(x, y, z), atol=tol)
  
file_path: pennylane/tests/optimize/test_optimize.py
imports: import pytest
  import pennylane
  from pennylane import numpy
  from pennylane.optimize import GradientDescentOptimizer, MomentumOptimizer, NesterovMomentumOptimizer, AdagradOptimizer, RMSPropOptimizer, AdamOptimizer
label_desc: Use image node_id 2 for calling the TestOverOpts obj's underlying member method code with example usage: obj.test_multi_args(mocker, opt, opt_name, tol) and returns: unknown