1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-30 22:53:59 +00:00

Conditionally compile API user services to save 4.3KB flash (follow-up to #9262) (#9451)

This commit is contained in:
J. Nick Koston
2025-07-11 19:08:03 -10:00
committed by GitHub
parent 0138ef36cf
commit dd5ba5a90c
23 changed files with 345 additions and 52 deletions

View File

@@ -0,0 +1,24 @@
esphome:
name: api-custom-services-test
host:
# This is required for CustomAPIDevice to work
api:
custom_services: true
# Also test that YAML services still work
actions:
- action: test_yaml_service
then:
- logger.log: "YAML service called"
logger:
level: DEBUG
# External component that uses CustomAPIDevice
external_components:
- source:
type: local
path: EXTERNAL_COMPONENT_PATH
components: [custom_api_device_component]
custom_api_device_component: