docstr: Test find_next_gate correctly identifies the next gate in a list of operations that share any number of wires.
docstr_tok: ["Test","find_next_gate","correctly","identifies","the","next","gate","in","a","list","of","operations","that","share","any","number","of","wires","."]
code: def test_find_next_gate(self, wires, op_list, next_gate_idx):
      """Test find_next_gate correctly identifies the next gate in a list of operations that share any number of wires."""
      assert (
          find_next_gate(qml.wires.Wires(wires), op_list)
          == next_gate_idx
      )
  
file_path: pennylane/tests/transforms/test_optimization/test_optimization_utils.py
imports: import pytest
  from utils import check_matrix_equivalence
  from pennylane.transforms.optimization.optimization_utils import find_next_gate, _zyz_to_quat, _quaternion_product, fuse_rot_angles
  import pennylane
  from pennylane import numpy
label_desc: Use image node_id 1 for calling the TestFindNextGate obj's underlying member method code with example usage: obj.test_find_next_gate(wires, op_list, next_gate_idx) without return types