TestProject Forum

DriverBuilder for Android Driver

Please help me to create a Driver Builder for Android Driver for Appium. I couldn’t find it on documentation.

Hello @gudimetl I
if you refer to Java, It is the same as Web Driver like ChromeDriver, just pass in the Android/IOS Drivers class with the correct desired capabilities, for example:

    AndroidDriver driver = new DriverBuilder<AndroidDriver>(new DesiredCapabilities())
            .withProjectName("Android Test")
            .withToken("YOUR DEV TOKEN")

This fine for Local Execution. If we want to create a Driver Builder for Android Driver to execute the tests in different machines connected to the net work.
What will be the Approach? Can you please let me know for Android Appium.

I have an Example for Web:
ChromeDriver driver = new DriverBuilder(new ChromeOptions())
.withRemoteAddress(new URL(“http://remote-agent-url:9999”))

Yes it is exactly the same, just add the remote address to the builder with your Android/Ios driver.

Hi @ran.tzur
I’m having errors while doing this format. Can you please give me a sample one contains all details. That will really helpful to me. Because here while providing the Host Address, it is giving continuous errors.