2

Run first test on Appium and I got a error in the logs.

Appium version 1.4.13
xcode version 7.2

iOS settings with appium: http://screenpresso.com/=nD2Cf. Here is my java code:

import io.appium.java_client.AppiumDriver;
import io.appium.java_client.MobileElement;
import io.appium.java_client.ios.IOSDriver;
import io.appium.java_client.remote.MobileCapabilityType;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.openqa.selenium.remote.RemoteWebDriver;

import java.net.MalformedURLException;
import java.net.URL;
import java.util.concurrent.TimeUnit;

/**
 * Created by betbull on 1/29/16.
 */
public class Runing {
    public static AppiumDriver wd;

    public static void main(String[] args) throws MalformedURLException {
        DesiredCapabilities capabilities = new DesiredCapabilities();
        capabilities.setCapability("appium-version", "1.4.13");
        capabilities.setCapability("platformName", "IOS");
        capabilities.setCapability("platformVersion", "9.2");
        capabilities.setCapability("deviceName", "iPhone6");
        capabilities.setCapability("app", "settings");
        wd = new IOSDriver(new URL("http://127.0.0.1:4723/wd/hub"), capabilities);
        wd.manage().timeouts().implicitlyWait(60, TimeUnit.SECONDS);
    }

}

logs with appium:

info: [debug] [INST STDERR] 2016-02-01 21:26:16.580 instruments[63237:1021849] WebKit Threading Violation - initial use of WebKit from a secondary thread.

info: [debug] [INST STDERR] 2016-02-01 21:26:21.158 instruments[63237:1021937] Attempting to change event horizon while disengage

info: [debug] [INST STDERR] 2016-02-01 21:26:21.159 instruments[63237:1021938] Attempting to change event horizon while disengage

info: [debug] [INST STDERR] Instruments *****Trace Error***** : Target failed to run: Permission to debug com.apple.Preferences was denied. The app must be signed with a development identity (e.g. iOS Developer).

info: [debug] [INSTSERVER] Instruments exited with code 253
info: [debug] Killall instruments

info: [debug] Instruments crashed on startup
info: [debug] Attempting to retry launching instruments, this is retry #1
info: [debug] Killall iOS Simulator
Zombies
  • 25,039
  • 43
  • 140
  • 225
  • Seems as if Instruments from XCode does not have proper access allowed on your machine. Try launching them independently once. – Naman Feb 02 '16 at 18:27

2 Answers2

1

Did you sign your application with a development certificate and set the Build Configuration to Debug (which is usually set to Release by default)? The app must be signed with a development identity (e.g. iOS Developer). tells me that you didn't.

As mentioned in this post and this post, simply set your scheme for your target under "Profile [App Name]".

Community
  • 1
  • 1
Demitrian
  • 3,200
  • 1
  • 24
  • 41
1

If changing the build configuration to debug doesn't work, close all the applications and try restarting the the system. This solved the problem for me.

Ashiq Sulaiman
  • 631
  • 1
  • 6
  • 14
  • Thanks this fixed my problem with the combination of other solutions. I have stopped all the running applications and restarted the computer. – Ebru Güngör Nov 02 '17 at 10:45