appium / appium-mac2-driver

Next-gen Appium macOS driver, backed by Apple XCTest
Apache License 2.0
115 stars 24 forks source link

Issue with sending a specific shortcut (Control + d + e + v) #304

Open superaleks opened 1 week ago

superaleks commented 1 week ago

Hi team,

As a part of one of automation projects for a Mac app we are working on, I've got to enable a specific environment by hitting Control + d + e + v key combination. I've tried the following as per documentation:

await browser.executeScript("macos: keys", [{ keys: [{ key: "d", modifierFlags: (1 << 2 )}, { key: "e", modifierFlags: (1 << 2 )}, { key: "v", modifierFlags: (1 << 2 )} ] } ]);

I can hear that some keyboard event is sent but I don't know exactly what, and I can't get info in the logs. Is this the correct way of hitting this key combo? Or is there something else?

mykola-mokhnach commented 1 week ago

You may check the xcuitest logs by enabling the appium:showServerLogs capability

superaleks commented 1 week ago

I already have this enabled but I see no logs on what key combination is pressed.

mykola-mokhnach commented 1 week ago

I don't have any other ideas, we completely rely on XCTest there. You may also try to run an AppleScript snippet as a possible alternative

superaleks commented 6 days ago

So what you are saying is that this issue is opened on the wrong board @mykola-mokhnach ?