class_docstr: Test that the wrapped NumPy functionality integrates well
  with standard NumPy functions.
class_docstr_tok: ["Test","that","the","wrapped","NumPy","functionality","integrates","well","with","standard","NumPy","functions","."]
docstr: Test that wrapped functions work correctly
docstr_tok: ["Test","that","wrapped","functions","work","correctly"]
code: def test_wrapped_function_on_tensor(self):
      """Test that wrapped functions work correctly"""
      x = np.array([0, 1, 2], requires_grad=True)
      res = np.sin(x)
      expected = onp.sin(onp.array([0, 1, 2]))
      assert np.all(res == expected)
      assert res.requires_grad
  
      # since the wrapping is dynamic, even ``sin`` will
      # now accept the requires_grad keyword argument.
      x = np.array([0, 1, 2], requires_grad=True)
      res = np.sin(x, requires_grad=False)
      expected = onp.sin(onp.array([0, 1, 2]))
      assert np.all(res == expected)
      assert not res.requires_grad
  
imports: import numpy
  import pytest
  from autograd.numpy.numpy_boxes import ArrayBox
  import pennylane
  from pennylane import numpy
  from pennylane.numpy.tensor import tensor_to_arraybox
label_desc: Use image node_id 5 for calling the TestNumpyIntegration obj's underlying member method code with example usage: obj.test_wrapped_function_on_tensor() without return types