Anchor all four wrap symbols, add 2-slot coverage, log outside the lock

This commit is contained in:
J. Nick Koston
2026-08-10 16:09:17 -05:00
parent 03a39597e8
commit 5b7a6d4e81
5 changed files with 49 additions and 8 deletions
@@ -0,0 +1,16 @@
esphome:
name: poolwrap-rp2-two
rp2:
board: rpipicow
wifi:
ssid: MySSID
password: password1
api:
rp2_ble_tracker:
bluetooth_proxy:
connection_slots: 2
@@ -27,6 +27,17 @@ def test_default_slots_emit_the_pool_wrap(
assert get_define_value("BLUETOOTH_PROXY_MAX_CONNECTIONS") == "3"
def test_two_slots_emit_the_pool_wrap(
generate_main: Callable[[str | Path], str],
component_config_path: Callable[[str], Path],
) -> None:
# Two slots: the wrap pools are smaller than the cap, sized from the count.
generate_main(component_config_path("rp2_proxy_two_slots.yaml"))
assert all(flag in CORE.build_flags for flag in WRAP_FLAGS)
assert get_define_value("ESPHOME_BLE_GATT_CLIENT_COUNT") == "2"
assert get_define_value("BLUETOOTH_PROXY_MAX_CONNECTIONS") == "2"
def test_single_slot_keeps_the_prebuilt_pools(
generate_main: Callable[[str | Path], str],
component_config_path: Callable[[str], Path],