I recently started working on iOS native app automation -
MAC OS 10.10.2 iOS simulator - iPhone 5s, iOS 8.1 Appium 1.3.4
App is in App store - I am using the .app file of this app store app
iOS settings in Appium.app - App path - gave path to .app file Force device - simulator device
Code -
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability("deviceName", "iPhone 5s");
capabilities.setCapability("platformName", "iOS");
driver = new IOSDriver(new URL("http://127.0.0.1:4723/wd/hub"),capabilities);
I also tried giving the app path onle in code but not in appium.app, I tried running with and without the bundle id of the app
But none of this works, I am not able to install the app in the simulator.
With the settings and code mentioned above I always get - Appium session could not be started. Instruments crashed
And when I give the bundle id of the app I get error as - A new session could not be created. (Original error: ENOENT, no such file or directory '/Applications/Appium.app/Contents/Resources/node_modules/appium/com.nbcuni.syfy.syfychannel/Info.plist')
Can someone please help me out?
Try this:
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability("platformName", "....");
capabilities.setCapability("deviceName", "....");
capabilities.setCapability("platformVersion", "...");
capabilities.setCapability("appPackage", "....");
capabilities.setCapability("appActivity", "...");
You should include "app" setting into your capabilities. It points to your .app or .ipa file. Also, if you want to be 100% sure that instruments are working run them directly: instruments -w "iPhone 5s" -t "Automation" ~/My.app -e UIASCRIPT my_script.js
my_script.js could be just empty.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.