firmware: keep temp config lookup outside UART guard

This commit is contained in:
2026-06-08 09:04:59 -06:00
parent 75c1d4d909
commit 954bef4291
2 changed files with 18 additions and 6 deletions
+12
View File
@@ -448,3 +448,15 @@ def test_legacy_dashboard_uart_is_disabled_by_default():
assert "DASHBOARD_UART_RX_PIN 22" not in config
assert "#if DASHBOARD_UART_ENABLED" in source
assert "pollDashboardUart();" in source
def test_temp_config_lookup_is_available_to_http_handlers():
source = firmware_source()
assert "int findTempConfigIndexById(" in source
assert "configIndex = findTempConfigIndexById(id);" in source
assert "findTempConfigIndexForUart" not in source
helper_pos = source.index("int findTempConfigIndexById(")
uart_guard_pos = source.index("#if DASHBOARD_UART_ENABLED")
assert helper_pos < uart_guard_pos