class_docstr: Tests for the ControlledQutritUnitary operation
class_docstr_tok: ["Tests","for","the","ControlledQutritUnitary","operation"]
docstr: Test if ControlledQutritUnitary raises a ValueError if a unitary of shape inconsistent
  with wires is provided
docstr_tok: ["Test","if","ControlledQutritUnitary","raises","a","ValueError","if","a","unitary","of","shape","inconsistent","with","wires","is","provided"]
code: def test_wrong_shape(self):
      """Test if ControlledQutritUnitary raises a ValueError if a unitary of shape inconsistent
      with wires is provided"""
      with pytest.raises(
          ValueError, match=r"Input unitary must be of shape \(3, 3\)"
      ):
          qml.ControlledQutritUnitary(
              np.eye(9), control_wires=[0, 1], wires=2
          ).matrix()
  
imports: import pytest
  import numpy
  from scipy.stats import unitary_group
  from gate_data import TSWAP
  import pennylane
  from pennylane.wires import Wires
  from pennylane.operation import DecompositionUndefinedError
label_desc: Use image node_id 3 for calling the TestControlledQutritUnitary obj's underlying member method code with example usage: obj.test_wrong_shape() without return types