From 4ec8fae5dfa791a01049e6007fe36d6473f8ae17 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Mon, 28 Sep 2026 19:26:51 +0200 Subject: [PATCH] [rp2] Enable the PlatformIO precompiled header (#19824) --- esphome/build_helpers/pch.py | 2 -- tests/unit_tests/build_helpers/test_pch.py | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/esphome/build_helpers/pch.py b/esphome/build_helpers/pch.py index 7889978f06..25dc9a7ae1 100644 --- a/esphome/build_helpers/pch.py +++ b/esphome/build_helpers/pch.py @@ -16,7 +16,6 @@ from esphome.const import ( PLATFORM_ESP32, PLATFORM_LN882X, PLATFORM_NRF52, - PLATFORM_RP2, PLATFORM_RTL87XX, ) from esphome.helpers import write_file_if_changed @@ -54,7 +53,6 @@ PCH_SCRIPT_EXCLUDED_PLATFORMS = frozenset( PLATFORM_ESP32, PLATFORM_LN882X, PLATFORM_NRF52, - PLATFORM_RP2, PLATFORM_RTL87XX, } ) diff --git a/tests/unit_tests/build_helpers/test_pch.py b/tests/unit_tests/build_helpers/test_pch.py index 0820da5be3..9ebcbe604b 100644 --- a/tests/unit_tests/build_helpers/test_pch.py +++ b/tests/unit_tests/build_helpers/test_pch.py @@ -109,7 +109,7 @@ def test_pch_checksum_tracks_closure_content(tmp_path: Path) -> None: assert base != pch.pch_checksum(tmp_path, ["root.h"], ["id"]) -@pytest.mark.parametrize("platform", ["esp8266"]) +@pytest.mark.parametrize("platform", ["esp8266", "rp2"]) def test_pch_script_enabled(platform: str, monkeypatch: pytest.MonkeyPatch) -> None: CORE.data[KEY_CORE] = {KEY_TARGET_PLATFORM: platform} assert pch.pch_script_enabled()