I need to automate the test code from my windows machine to iOS simulator, Appium server.
I have my test code in my Windows machine.
I have my Appium server, simulator in the iOS machine.
Currently, I’m manually starting the Appium server in iOS machine and then I’m running the test code in my windows machine.
Now, I need to start the Appium server from the test code (Windows Machine). When the test code started running it should trigger the Appium server in the iOS Machine.
This is my current code:
public static void startApplication() throws Exception{
System.out.println("Into iOS");
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability(MobileCapabilityType.PLATFORM_NAME, "iOS");
capabilities.setCapability(MobileCapabilityType.PLATFORM_VERSION, "8.2");
capabilities.setCapability(MobileCapabilityType.DEVICE_NAME, "iPad Air");
capabilities.setCapability(MobileCapabilityType.APP,"/Users/selvakumar/Library/Developer/Xcode/DerivedData/InsuranceDemo-bhtkygawfxwcaldbzilyzujfozxd/Build/Products/Debug-iphonesimulator/InsuranceDemo.app");
driver = new RemoteWebDriver(new URL("http://172.16.9.162:4723/wd/hub"), capabilities);
System.out.println("Appium SetUp for Android is successful and Appium Driver is launched successfully");
}
I have mentioned the iOS Machine IP address in the Remote Web Driver to access the ios machine.
How to access the iOS machine Appium server. Suggestions and comments are welcome.