class_docstr: Tests for the qml.map_wires method used with tapes.
class_docstr_tok: ["Tests","for","the","qml.map_wires","method","used","with","tapes","."]
docstr: Test the map_wires method with a tape.
docstr_tok: ["Test","the","map_wires","method","with","a","tape","."]
code: def test_map_wires_tape(self, shots):
      """Test the map_wires method with a tape."""
      with qml.queuing.AnnotatedQueue() as q_tape:
          build_op()
  
      tape = QuantumScript.from_queue(q_tape, shots=shots)
      tape.trainable_params = [0, 2]
      # TODO: Use qml.equal when supported
  
      s_tapes, _ = qml.map_wires(tape, wire_map=wire_map)
      s_tape = s_tapes[0]
      assert len(s_tape) == 1
      assert s_tape.trainable_params == [0, 2]
      s_op = s_tape[0]
      assert isinstance(s_op, qml.ops.Prod)  # pylint:disable=no-member
      assert s_op.data == mapped_op.data
      assert s_op.wires == mapped_op.wires
      assert s_op.arithmetic_depth == mapped_op.arithmetic_depth
      assert tape.shots == s_tape.shots
  
imports: from functools import partial
  import pytest
  import pennylane
  from pennylane.ops import Prod
  from pennylane.tape import QuantumScript
  from pennylane.wires import Wires
label_desc: Use image node_id 1 for calling the TestMapWiresTapes obj's underlying member method code with example usage: obj.test_map_wires_tape(shots) without return types