diff --git a/esphome/arduino8266/framework.py b/esphome/arduino8266/framework.py index a574313f49..5ca305e0ef 100644 --- a/esphome/arduino8266/framework.py +++ b/esphome/arduino8266/framework.py @@ -142,8 +142,9 @@ def check_and_install(framework_version: Version) -> InstalledPaths: # Sentinel: "resolve for me" (None is a real value meaning disabled). -# run_compile resolves once and threads the result so one build never pays -# the PATH scan and runnability probe three times. +# The native run_compile (a later PR in the chain) will resolve once and +# thread the result so one build never pays the PATH scan and runnability +# probe three times. CCACHE_UNRESOLVED: Any = object() diff --git a/tests/unit_tests/test_arduino8266_framework.py b/tests/unit_tests/test_arduino8266_framework.py index cd79c57f8f..c173fb27f2 100644 --- a/tests/unit_tests/test_arduino8266_framework.py +++ b/tests/unit_tests/test_arduino8266_framework.py @@ -157,7 +157,10 @@ def test_get_build_env_without_path_has_no_empty_entry(tmp_path: Path) -> None: def test_ccache_env_accepts_a_preresolved_path() -> None: """A caller that already resolved ccache threads it through; the probe must not run again (None means resolved-and-disabled).""" - with patch.object(framework, "ccache_path") as mock_resolve: + with ( + patch.dict(os.environ, {}, clear=True), + patch.object(framework, "ccache_path") as mock_resolve, + ): assert framework.ccache_env(None) == {} env = framework.ccache_env("/usr/bin/ccache") mock_resolve.assert_not_called()