diff --git a/api/tests/samples/config-11/packages/ha.yaml b/api/tests/samples/config-11/packages/ha.yaml index 6bae0a9..b1a9b8b 100644 --- a/api/tests/samples/config-11/packages/ha.yaml +++ b/api/tests/samples/config-11/packages/ha.yaml @@ -1 +1,38 @@ automation: !include ../automations/ui.yaml +media_player: + - platform: template + media_players: + receiver: + friendly_name: Receiver + current_source_template: "{{ states('input_text.selected_source') }}" + value_template: > + {% if is_state("input_boolean.receiver_on", "on") -%} + on + {%- else -%} + off + {%- endif %} + turn_on: + service: switch.turn_on + data_template: + entity_id: switch.receiver_on + turn_off: + service: switch.turn_on + data_template: + entity_id: switch.receiver_off + volume_up: + service: switch.turn_on + data_template: + entity_id: switch.volume_up + volume_down: + service: switch.turn_on + data_template: + entity_id: switch.vol + input_templates: + source 1: + service: input_boolean.turn_on + data_template: + entity_id: input_boolean.source_1 + source 2: + service: input_boolean.turn_on + data_template: + entity_id: input_boolean.source_2