Objective
The small partners who have done the app test on iOS should know that the normal user installs the app from the AppStore, installs the test version of the app, is usually developed to the QR Code Scan code installation,
or develop an. IPA installation package file, which is installed through itools. It's not that easy to install app testing on an iOS simulator for a small partner who doesn't have an iphone real-world device.
First, start iOS Simulator
1.xcode>open Developer Tool>ios Simulator, open and select the corresponding iphone version in hardware to launch the simulator.
2. The second method, start the simulator via the command:
$ xcrun instruments-w ' device name '
Note: The device name here must be in this format: IPhone 6 (10.3)
Two, get. App Pack
1. Here the popular science (knocking the blackboard, remember the emphasis), on the real machine is installed. IPA packages, which are installed on the emulator. App package.
This is two different ways of packaging, that is, downloaded from the AppStore channel. IPA cannot be installed on the emulator, you have to develop a package specifically for the iOS simulator to play a simulator, the suffix is. App.
(Don't ask me how I know, it's all tears ~ ~ ~)
2. Take https://github.com/appium/sample-code.git one of the. App packages as an example, in the path/sample-code/apps/testapp/build/ There's a Testapp.app under Release-iphonesimulator.
This is what can be installed directly on the iOS simulator
3. Install to the simulator via the instructions:
$ xcrun Simctl Install Booted/path/to/xxx.app
Remark:/path/to/xxx.app This is the absolute path of the. App package, you can enter the previous instruction, and then find the package and drag it directly to the terminal.
4. Uninstall the app's instructions:
$ xcrun simctl Uninstall booted Xxx.app
Xxx.app is the package name, there is no need for a path, such as: Testapp.app
Third, Xcode-select
1. If you encounter Xcrun error: Xcrun:error:active developer path ("/applications/xcode.app/contents/developer") does not exist
According to the error prompt, enter the instructions to solve the prompt:
$ sudo xcode-select--switch Path/to/xcode.app
Similarly, here Path/to/xcode.app is also the absolute path of Xcode in application, directly find the icon to drag to the terminal on the line
2. Or enter this to:
$ xcode-select--install
Iv. Summary
1. The iOS simulator must be called through Xcode. App install package, Real machine package (. IPA) Select Debug-iphone OS, Simulator package (. App) Select Debug-iphone Simulator
2. The following methods can be installed on the simulator:
--run the script, will be installed automatically, refer to: Appium+python Automation 17-launch iOS simulator app source case
--by means of an instruction installation, which is what this article says
--can be installed through the configuration on the Appium, the next Appium debugging app when positioning elements
-If will Xcode, you can get the source code directly, with Xcode directly run up
Appium+python Automated 19-ios Simulator (IOS Simulator) installs home app