Unable to close a pop-up in Chrome

My colleague and I are confronted to a problem. We are automating with Katalon Studio the tests of a web interface on an emulated (by Android Studio) Pixel 4. During the test, we need to access the camera of the emulated phone. We see a pop-up asking us if we want to allow or block the software from accessing the camera. This pop-up just can’t be closed. We have tried:

  1. acceptAlert() and dismissAlert(): com.kms.katalon.core.exception.StepFailedException: No alert found
  2. edit Project --> Settings --> Desired capabilities --> Mobile --> Android : prefs = {autoGrantPermissions = true}, args = {profile.default_content_setting_values.media_stream_camera = 1} --> does not close the pop-up
  3. click on the object: it is not a capturable object.
  4. switchToWindowIndex(1): no such window

I am clueless. Any ideas ? Thanks in advance.

Is there a title on the pop-up that you can use?

WebUI.switchToWindowTitle("popup title")

Thanks for your reply. I’m afraid not…