def test_qnode_fails_on_combination_of_cv_and_qbit_ops(self, qubit_device_1_wire):
    'CV and discrete operations must not be mixed'

    @qml.qnode(qubit_device_1_wire, interface='tf')
    def qf(x):
        qml.RX(x, wires=[0])
        qml.Displacement(0.5, 0, wires=[0])
        return qml.expval(qml.PauliZ(0))
    with pytest.raises(QuantumFunctionError, match='Continuous and discrete'):
        qf(Variable(0.5))
CV and discrete operations must not be mixed
def test_qnode_fails_on_combination_of_cv_and_qbit_ops(self, qubit_device_1_wire):
    

    @qml.qnode(qubit_device_1_wire, interface='tf')
    def qf(x):
        qml.RX(x, wires=[0])
        qml.Displacement(0.5, 0, wires=[0])
        return qml.expval(qml.PauliZ(0))
    with pytest.raises(QuantumFunctionError, match='Continuous and discrete'):
        qf(Variable(0.5))