microsoft / WinAppDriver

Windows Application Driver
MIT License
3.54k stars 1.39k forks source link

How to start WinAppDriver as a non-admin user #1983

Open aries-zhang opened 2 months ago

aries-zhang commented 2 months ago

Hi team, quite opposite to this issue: https://github.com/microsoft/WinAppDriver/issues/1908, in my use case, the app being tested does not work under elevated permissions, so it has to run as a non-admin user to properly function.

Is there a way to specify a runAs user in the WinAppDriver ADO task?

  - task: Windows Application Driver@0
    inputs:
      OperationType: Start
      AgentResolution: 1080p
anunay1 commented 2 months ago

By default it will run as a user. Unless you specify to run it as admin.

anunay1 commented 2 months ago

Is it azure ADO task? If yes then run the test agent as user and not admin.

aries-zhang commented 2 months ago

Yes it is an ADO task which runs as a user with elevated permission. Is there a way to specify the test agent to run as user without customizing the image? Found this link but self-hosting is not an option due to compliance/security reasons for us.

image

anunay1 commented 2 months ago

I know for sure self hosted agent it's possible, not sure about MS hosted agent. You need to raise a support ticket with Microsoft.

aries-zhang commented 2 months ago

Will do, thanks @anunay1 👍