def test_qnode_fails_for_cv_ops_on_qubit_device(self, qubit_device_1_wire):
    'A qubit device cannot execute CV operations'

    @qml.qnode(qubit_device_1_wire, interface='tf')
    def qf(x):
        qml.Displacement(0.5, 0, wires=[0])
        return qml.expval(qml.X(0))
    with pytest.raises(DeviceError, match='Gate [a-zA-Z]+ not supported on device'):
        qf(Variable(0.5))
A qubit device cannot execute CV operations
def test_qnode_fails_for_cv_ops_on_qubit_device(self, qubit_device_1_wire):
    

    @qml.qnode(qubit_device_1_wire, interface='tf')
    def qf(x):
        qml.Displacement(0.5, 0, wires=[0])
        return qml.expval(qml.X(0))
    with pytest.raises(DeviceError, match='Gate [a-zA-Z]+ not supported on device'):
        qf(Variable(0.5))