aboutsummaryrefslogtreecommitdiff
path: root/tests/multi_bluetooth/ble_gap_device_name.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/multi_bluetooth/ble_gap_device_name.py')
-rw-r--r--tests/multi_bluetooth/ble_gap_device_name.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/multi_bluetooth/ble_gap_device_name.py b/tests/multi_bluetooth/ble_gap_device_name.py
index e7202170b..556068114 100644
--- a/tests/multi_bluetooth/ble_gap_device_name.py
+++ b/tests/multi_bluetooth/ble_gap_device_name.py
@@ -49,9 +49,7 @@ def wait_for_event(event, timeout_ms):
t0 = time.ticks_ms()
while time.ticks_diff(time.ticks_ms(), t0) < timeout_ms:
if event in waiting_events:
- result = waiting_events[event]
- del waiting_events[event]
- return result
+ return waiting_events.pop(event)
machine.idle()
raise ValueError("Timeout waiting for {}".format(event))