问题
I need to screen record iOS from iMAC for the purpose of test automation. I found commands for Android and iOS-Simulator which are:
- adb screenrecord /sdcard/123.mp4
- xcrun simctl io recordVideo --type=mp4
However, I need a command for iOS-real device.
The purpose of this is for taking video of device during each of test automation sessions.
回答1:
iOS 11 has built-in Screen Recording for real devices, you need to check if its possible to do run/stop/getFile from device via command line tools or whatever using in terminal.
In addition, its possible to use QuickTime + Applescript
for screen recording, check here for details.
来源:https://stackoverflow.com/questions/47279619/how-to-screen-record-ios-real-device-with-command