test(core): add a simple test for `BleUnpair`
What changed, and why it matters
This commit only adds a new automated test that checks the Bluetooth 'unpair all' feature on one Trezor model. It does not change any production firmware code, so it cannot introduce a security vulnerability by itself.
No security action needed; treat as routine test coverage addition.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The diff creates tests/device_tests/test_ble.py with a single pytest case for the BleUnpair message (all=True) on the T3W1 model, plus corresponding UI fixture hashes in tests/ui_tests/fixtures.json for multiple languages. No firmware source files are modified.
Changed components
tests/device_tests/test_ble.pytests/ui_tests/fixtures.jsonInspect captured patch +17 / −0
diff --git a/tests/device_tests/test_ble.py b/tests/device_tests/test_ble.py
new file mode 100644
index 000000000..1e349d24d
--- /dev/null
+++ b/tests/device_tests/test_ble.py
@@ -0,0 +1,11 @@
+import pytest
+
+from trezorlib import ble
+from trezorlib.debuglink import SessionDebugWrapper as Session
+
+
+@pytest.mark.models("t3w1")
+def test_ble_unpair_all(session: Session):
+ ble.unpair(session, all=True)
+ # `Success` is sent before unpairing is done, so we'll send another command just to "flush" the last screen.
+ session.ping("")
diff --git a/tests/ui_tests/fixtures.json b/tests/ui_tests/fixtures.json
index 7834b29ff..6de718427 100644
--- a/tests/ui_tests/fixtures.json
+++ b/tests/ui_tests/fixtures.json
@@ -30437,6 +30437,7 @@
"T3W1_cs_test_basic.py::test_device_id_different": "7603cf8eb5bff844dea05e3bcc0510187bc9aaec1d800d56287e2326f121169c",
"T3W1_cs_test_basic.py::test_device_id_same": "e86f70857903b875db5a771e3b605b664a64479494e95ae9df5f7cad094e846d",
"T3W1_cs_test_basic.py::test_ping": "c24521e569c08e3605b164212c876f8ac57c5eef6cca6f2ca53a635a883ebc4b",
+"T3W1_cs_test_ble.py::test_ble_unpair_all": "9a8cb77f32c5b5d23e6e03d6cee3dd6c48ae503749e8d4a4abdff7dcd46ed645",
"T3W1_cs_test_busy_state.py::test_busy_expiry_core": "9f4d831de73e586dac1af47d844bf78be2d67408d4e3540dc30c6bce94c9a183",
"T3W1_cs_test_busy_state.py::test_busy_state": "16d35c8e6b845cc5eff55145fa947aa2e1859b90f2506ea15d2dded8a22ff26f",
"T3W1_cs_test_cancel.py::test_cancel_message_via_cancel[message0]": "62bed332244d46efd965f95dedc03a8bdfb440d2ea5f05631b8bbb54b3b50ffe",
@@ -31919,6 +31920,7 @@
"T3W1_de_test_basic.py::test_device_id_different": "46c80c7a5668f663fd3a1867a21c00915e598399208bb7d216de3f5a4266ffe2",
"T3W1_de_test_basic.py::test_device_id_same": "a7d331033c12d91842d1d7e3abf11de209f66149df781ba6465377434374ef2a",
"T3W1_de_test_basic.py::test_ping": "98735f888f827501b25c78c6a737c1983a800c620f709c65b1d95f6c8c9a2b90",
+"T3W1_de_test_ble.py::test_ble_unpair_all": "60298f3d1fb399e2bcea8cdff7b4542febcd08dc25bb1674fe09ed3eaea1559e",
"T3W1_de_test_busy_state.py::test_busy_expiry_core": "fe8e5dbe730131ba33c6800cbc7ea5e3f6ec35952e74b403257435e4c8ae9542",
"T3W1_de_test_busy_state.py::test_busy_state": "f5cfb62f03892a9edbf9709c2355c43d189a3163333cc82f9292dab836de417d",
"T3W1_de_test_cancel.py::test_cancel_message_via_cancel[message0]": "8466d6aa0191cbf44d11437c15187148c41044a77716991e5506fde4fd7b6518",
@@ -33401,6 +33403,7 @@
"T3W1_en_test_basic.py::test_device_id_different": "c26f7f469cd661ac8a46537a8930716f27c4c4f80d82bbde5d7bb7fde6ea09e1",
"T3W1_en_test_basic.py::test_device_id_same": "cb9177964a8876eeba27aba72c2fdaed60c37e0b21d4827287c9c3b562147661",
"T3W1_en_test_basic.py::test_ping": "931d9afceb0ba1e4faae891775819277242d889644d5c0c5863fc8c9fcf859b1",
+"T3W1_en_test_ble.py::test_ble_unpair_all": "4be9606be0d89e633be35e0f05b23fac0f45c21b658817bad7d8bd474a81da50",
"T3W1_en_test_busy_state.py::test_busy_expiry_core": "9911b2c22ec3e01fd2997c8ea579dd4a40cb8f83924925704e0aa8fd163a92a9",
"T3W1_en_test_busy_state.py::test_busy_state": "26e350c7f41d424f82fc66c37267fbf4fae2a94ddc40b3434ee050c51ece0887",
"T3W1_en_test_cancel.py::test_cancel_message_via_cancel[message0]": "554305cd87d6bbdbcabf796978bc16c32ac8395b114bddfe1d856b359f2423a7",
@@ -34883,6 +34886,7 @@
"T3W1_es_test_basic.py::test_device_id_different": "3275e1355569d611e982a6d49e02cc5a3ff5b7be91e2f5f378804a59d9476eea",
"T3W1_es_test_basic.py::test_device_id_same": "28fef3a57d720b8804bc8e936c5171417465a1882bbb850eb0ef9e6c9ace0a4b",
"T3W1_es_test_basic.py::test_ping": "56536ae9cd7c4ff8022def4ec3350031d3614064d961f53a2850f2be425af201",
+"T3W1_es_test_ble.py::test_ble_unpair_all": "2f3e60f4ddd94edab8b87a69509b1b4f342dad84016b71674b0eaefdf9b72fd7",
"T3W1_es_test_busy_state.py::test_busy_expiry_core": "bdb4e38629312d5a49ccf65b2f3c8fc5c9ac65146ed08ee52cb6d01a20bafedd",
"T3W1_es_test_busy_state.py::test_busy_state": "28fee3788fde608e6bf14ba91898848c26a78aeffe055e7689ba965f13ed2e4b",
"T3W1_es_test_cancel.py::test_cancel_message_via_cancel[message0]": "0a74d5a1c99fc831e116192316a95f13c352cd62500cd1dbc2b31f5d8092247a",
@@ -36365,6 +36369,7 @@
"T3W1_fr_test_basic.py::test_device_id_different": "c5431434e76680cde7e5bc2dfefe79a67eb916c382f89728bf2e152166c0556b",
"T3W1_fr_test_basic.py::test_device_id_same": "7ee2accc37d63526986ed343f4a236486613caec2a9954d6ffa70ed9a97cbf61",
"T3W1_fr_test_basic.py::test_ping": "e8156cf4eda1d29060f05b4a18d50032b0b344230609b7de7cababfe0a86b20b",
+"T3W1_fr_test_ble.py::test_ble_unpair_all": "fba69d8675c14ee3c58c06615a236689047db0be7960cb7d919830a80e352315",
"T3W1_fr_test_busy_state.py::test_busy_expiry_core": "69d2c1c33ee7f284bb47e79ddd1bd15b980309a3dcf8d6afd2a7928842c301a0",
"T3W1_fr_test_busy_state.py::test_busy_state": "312fe11959079b4768cdd9a7fe612a0251f9388c7188fce5ccab09c54afbefc6",
"T3W1_fr_test_cancel.py::test_cancel_message_via_cancel[message0]": "7e9993594536860786bdb06982f25e4e4e5f7fc33c2efbc68be309b6c1345c36",
@@ -37847,6 +37852,7 @@
"T3W1_pt_test_basic.py::test_device_id_different": "d13fa8de856b903b099f296accf2318337a260624c5498fa1d7e53de98b1a382",
"T3W1_pt_test_basic.py::test_device_id_same": "b864f2161dbe827b5b546d57b21818ab39220fce5d9f6aee67267483eec93bd1",
"T3W1_pt_test_basic.py::test_ping": "1c74667c078e25e7e0d37c7b2aa35f7c8ab02cd88e74695ecb355c82a293b0cc",
+"T3W1_pt_test_ble.py::test_ble_unpair_all": "ab03cd3fa139e7776daa6b22895954047bcbf3fc130d4c4dc5517a4fd6b6cdaf",
"T3W1_pt_test_busy_state.py::test_busy_expiry_core": "9c300b20e5174425dfdfcf08f6a1a672fdd56dc8d14acb87331a35a19e60c47c",
"T3W1_pt_test_busy_state.py::test_busy_state": "cdea3664f580da565de05bcfce0d75cbb348d7c6ecaf0c6187c6fcb5863c69f7",
"T3W1_pt_test_cancel.py::test_cancel_message_via_cancel[message0]": "947b4ab58e7807a316763c0364f3b454a0c5be8cffd3796a2b6fd6a6b7d3a346",
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.