Ejemplo n.º 1
0
def device(hass, mock_openzwave):
    """Fixture to provide a precreated climate device."""
    node = MockNode()
    values = MockEntityValues(
        primary=MockValue(data=1, node=node),
        temperature=MockValue(data=5, node=node, units=None),
        mode=MockValue(data='test1', data_items=[0, 1, 2], node=node),
        fan_mode=MockValue(data='test2', data_items=[3, 4, 5], node=node),
        operating_state=MockValue(data=6, node=node),
        fan_state=MockValue(data=7, node=node),
    )
    device = zwave.get_device(hass, node=node, values=values, node_config={})

    yield device
Ejemplo n.º 2
0
def device(hass, mock_openzwave):
    """Fixture to provide a precreated climate device."""
    node = MockNode()
    values = MockEntityValues(
        primary=MockValue(data=1, node=node),
        temperature=MockValue(data=5, node=node, units=None),
        mode=MockValue(data=b'test1', data_items=[0, 1, 2], node=node),
        fan_mode=MockValue(data=b'test2', data_items=[3, 4, 5], node=node),
        operating_state=MockValue(data=6, node=node),
        fan_state=MockValue(data=7, node=node),
    )
    device = zwave.get_device(hass, node=node, values=values, node_config={})

    yield device
Ejemplo n.º 3
0
def device_zxt_120(hass, mock_openzwave):
    """Fixture to provide a precreated climate device."""
    node = MockNode(manufacturer_id='5254', product_id='8377')
    values = MockEntityValues(
        primary=MockValue(data=1, node=node),
        temperature=MockValue(data=5, node=node),
        mode=MockValue(data=b'test1', data_items=[0, 1, 2], node=node),
        fan_mode=MockValue(data=b'test2', data_items=[3, 4, 5], node=node),
        operating_state=MockValue(data=6, node=node),
        fan_state=MockValue(data=7, node=node),
        zxt_120_swing_mode=MockValue(
            data=b'test3', data_items=[6, 7, 8], node=node),
    )
    device = zwave.get_device(hass, node=node, values=values, node_config={})

    yield device