iOS Automation Appium:如何在没有持续时间的情况下锁定iPhone真实设备的屏幕?

问题描述:


我想自动进行以下操作:锁定我的真实设备的屏幕,然后再次从APNS打开屏幕-就像从APNS接听电话一样.因此,我只想在没有一定时间的情况下锁定屏幕,以便可以通过滑动推送通知来解锁屏幕.我知道AppiumDriver中有 lockScreen(int seconds) ,但我只想实现 lockScreen() 方法.
你们每个人都有一个想法怎么做?如何使用Apple脚本或Appium驱动程序解决该问题?
非常感谢
朱尔斯


I want to automate the following case: locking my screen of the real device and open the screen again from an APNS - like answer a call from APNS. Therefore I would like to just lock the screen without a certain amount of time, so that I can unlock it by swiping on the push notification. I know there is in AppiumDriver the lockScreen(int seconds) but I just want to implement lockScreen() method.
Any of you have an idea how to do that? How I could solve that with Apple script or with Appium Driver?
thanks a lot
Jules

这是所需的行为.锁定-等待-解锁对于iOS是必需的,在iOS上,这是进行任何锁定的唯一方法.对于Android,它应该只是锁定.如果要解锁,可以致电解锁.

This is the desired behavior. The locking-waiting-unlocking is necessary for iOS, where it is the only way to do any locking. For Android it should just lock. If you want it to unlock, you can call unlock.