This site is in read only mode. Please continue to browse, but replying, likes, and other actions are disabled for now.
11 / 45
Oct 2015

Hi All,

I have gone through the above the Pre-requisites and I have done the same set up but I got stuck @ one step.

These things I have already done - SafariLauncher is installed via XCODE on IPAD Mini Air (9.3) and device is also connected using os-webkit-debug-proxy.

But when I am running test I am getting below exception

==================================================

info: [debug] Error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'
at Error (native)
info: [debug] Responding to client with error: {"status":33,"value":{"message":"A new session could not be created. (Original error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip')","errno":-2,"code":"ENOENT","path":"/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip","origValue":"ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'"},"sessionId":null}

error: Failed to start an Appium session, err was: Error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'

info: <-- POST /wd/hub/session 500 162.301 ms - 498

===========================================

Can anyone guide me here ??

Thanks & Regards
Mukesh

Download XCode and Install it. After installation import the SafariLauncher in xcode and Run it.

Once build is successful, it will installed SafariLauncher in your device

Friends, I did all my setup. That is setting up Safari Launcher and webkit proxy as well. The problem is when I start the test Safari Launcher starts and opens up the browser but no URL launches. Just the apple.com page launches.

The same test runs well on Simulator.

Hey @yukonpd, you should launch the url from your test scripts, not the SafariLauncher.
If you would like to change the first launched page from the SafariLauncher, you should open it with Xcode and change the Default Value of Root.plist

Thanks @mferturk for your reply,
I launched the URL from the test scripts itself, below is the snippet:

Web driver class{

  private WebDriver setMobileDriver(Map<String, String> selConfig) {

        DesiredCapabilities cap = new DesiredCapabilities();
	String [] appiumDeviceConfig = selConfig.get("mobileDevice").split(":"); 
	cap.setCapability("deviceName", appiumDeviceConfig[0]);
	cap.setCapability("automationName", "Appium");
	cap.setCapability("platformName", "iOS");
	String appiumServerHostUrl = selConfig.get("appiumServer");
	URL appiumServerHost = null;
	try {
		appiumServerHost = new URL(appiumServerHostUrl);
	} catch (MalformedURLException e) {
		e.printStackTrace();
	}
	cap.setJavascriptEnabled(true);
	System.out.println(appiumServerHostUrl);
	AppiumDriver driver=new IOSDriver(appiumServerHost, cap);
	
	try {
		Thread.sleep(30000);
		System.out.println("now entering url");
	} catch (InterruptedException e) {
		// TODO Auto-generated catch block
		e.printStackTrace();
	}
	driver.get("https://google.com");

Just to remind the same lines work on the Simulator, I have appium 3.1.0 version under my POM.xml. Just let me know if you need more info.

14 days later

Hi Friends,

My mobile application is a iOS Native app. Please go through the below steps
1. After Launching the app there is a button called Forgot Your PIN
2. When we click on Forgot Your PIN button.
3. The application will redirect to a Safari Web page where I have the below fields.
4. Mobile Number, Last Name and Data of Birth Picker.
5. I am unable to tap or select Mobile Number field by using Tap feature of Safari browser using Appium Inspector.

So please someone help me how to tap or select Mobile number field of a browser.

Hi yukonpd,

I have the same issue with you.
Did you solve it? Could you share for us your solution?

19 days later

Hi Friends,

No till now I did not get any solution, if anything is there i will let you know guys.

Thanking you,
Bhaskar.M

Hi, I am facing issue with safari on real device. SafariLauncher opens the safari browser on device but did not hit my URL.
set following capabilities
deviceUDID= xxxxxx
bundleid= com.apple.mobilesafari
appium-version =1.4.11
browserName =Safari
platformName =iOS
deviceName =iPhone 6
platformVersion =8.4

21 days later

Hi Mukesh,

I got the same error which you were getting earlier, could you please confirm whether you got a solution for this.

info: --> POST /wd/hub/session {"desiredCapabilities":{"appium-version":"1.4.13","platformName":"iOS","deviceName":"Bin_iPhone","udid":"1f789643be7b96813c4d2ae5b037bc27cb1b4a26","bundleId":"com.binoy.safarilauncher","browserName":"safari","version":"8.4.1"}}

info: Client User-Agent string: undefined
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: **** NEW SESSION ***
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: *************************************
info: [debug] The following desired capabilities were provided, but not recognized by appium. They will be passed on to any other services running on this server. : appium-version, version

error: Failed to start an Appium session, err was: Error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'

info: [debug] Configuring Safari session
info: [debug] Using local .zip from command line: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip
info: [debug] Copying local zip to tmp dir
info: [debug] Got configuration error, not starting session
info: [debug] Cleaning up appium session
info: [debug] Error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'
at Error (native)
info: [debug] Responding to client with error: {"status":33,"value":{"message":"A new session could not be created. (Original error: ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip')","errno":-2,"code":"ENOENT","path":"/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip","origValue":"ENOENT, stat '/Applications/Appium.app/Contents/Resources/node_modules/appium/build/SafariLauncher/SafariLauncher.zip'"},"sessionId":null}
info: <-- POST /wd/hub/session 500 4.849 ms - 498

Thanks
Bin

14 days later

Hi Everyone.

I couldn't understand setp2 , if you can explain in details. rest all i did and my Safari launcher installed on Iphone. I can load it mannualy but when i use Appium to Launch.
1. Server Run without Any Error
2. Mobile asked for Passcode
3. Once Passcode Entered nothing happen- Application Didn't open
4. Server running
5. No Java Errors

Can anyone help please what i am doing wrong.

Thanks

Just to update thread, if anyone got same issue. Removed Passcode from setting and now running perfectly fine

23 days later

Great tutorial/documentation!!!

I recently tried mobile web automation on real iOS device using the following:
OS X Yosemite 10.10.5
Xcode 7.2.1
iOS Device (9.2.1)
Appium (1.4.16)

More importantly, using a free ios development provisioning profile!

See http://goo.gl/nId1rr252 for more details!

9 days later

I have been trying to connect my iPad to mac over wifi to run the appium tests. I know how tests works with android devices over wifi, but not how to do it with iOS devices. Please update if any one has worked on how to get it done.