WinAppDriver icon indicating copy to clipboard operation
WinAppDriver copied to clipboard

WinAppDriver.Exe Fails to Find Button in Title Bar When Run as Administrator (Must Run as Admin to run on a non-default port)

Open ronjonesjr opened this issue 8 years ago • 3 comments

I have a test case that uses accessibility ID to find a button that is on the title bar of a Windows application. That button is found when I run WinAppDriver.exe via a regular user account, but it fails when I run it as an administrator account. This happens when running WinAppDriver.exe directly and when I run it via Appium.

This is an issue because the documentation for WinAppDriver.exe, and Appium/Appium-Desktop for that matter, states that you must run WinAppDriver.exe as administrator to change the port. As a side point, it seems there's a design conflict with Appium Desktop as well because in order to run WinAppDriver.exe as admin you must run Appium Desktop as admin (it launches WinAppDriver.exe as needed under the same account). Appium Desktop runs WinAppDriver.exe on port 4724 (non default) and thus per the WinAppDriver documentation, if it's correct, you must run Appium Desktop as admin so that WinAppDriver.exe is also run as admin so that it can successfully use port 4724.

ronjonesjr avatar Jul 24 '18 19:07 ronjonesjr

Hi @ronjonesjr,

You don't need to run as admin to set the port - we'll update our documentation to clarify this. You are required to run as admin to use a non-loopback IP.

hassanuz avatar Jul 31 '18 22:07 hassanuz

Ok but there’s still a bug

~Ron

On Jul 31, 2018, at 6:33 PM, Hassan Uraizee [email protected] wrote:

Hi @ronjonesjr,

You don't need to run as admin to set the port - we'll update our documentation to clarify this. You are required to run as admin to use a non-loopback IP.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

ronjonesjr avatar Aug 01 '18 01:08 ronjonesjr

Thanks @ronjonesjr.

We'll try to repro behavior difference when running WinAppDriver as admin. It would be great if you can provide any additional information to help us with reproduction (e.g. what kind of button you're hitting, what type of app (UWP, Win32, Winforms, WPF), etc).

hassanuz avatar Aug 07 '18 23:08 hassanuz