Re: [web-bluetooth] bluetooth.gattEventGenerated and bluetooth.simulateGattResponse for Web Bluetooth automation (#650)

Hi Reilly,

Could you please take a look at this patch to see if this pattern is on the right track to support these commands? I tried to leverage `upon fulfillment of promise` to make the special steps for simulation limited to only around the text for performing GATT connection and service discovery.

Additionally, for the following PR for supporting add/removing services/characteristics/descriptors, I plan to have those  simulation commands create promises in [Bluetooth.[[attributeInstanceMap]]](https://webbluetoothcg.github.io/web-bluetooth/#dom-bluetooth-attributeinstancemap-slot), so that they will align with what I proposed in this PR.



-- 
GitHub Notification of comment by chengweih001
Please view or discuss this issue at https://github.com/WebBluetoothCG/web-bluetooth/pull/650#issuecomment-2764428042 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Sunday, 30 March 2025 07:27:29 UTC