There is any way to automate fire TV using appium

We are trying to automate an application which is installed on fire TV.

We need a solution that how to automate fire TV.

1 Like

Jitu

Did you find any way ?. Please share any useful information regarding this

Yes i am able to automate fire Tv using Appium

Its same as Android device.

Both have some unique udid right.

Can you please share some basic steps and setup in order to connect the TV with appium and start inspecting elements?
Thanks in advance!..

RUn the below code and let me know if Application is launching on TV or not.
public AndroidDriver initializeAndroidDriver() {
AndroidDriver driver = null;
@SuppressWarnings(“rawtypes”)
DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability(MobileCapabilityType.VERSION, appiumInit.VERSION);
capabilities.setCapability(MobileCapabilityType.PLATFORM_NAME, appiumInit.PLATFORM_NAME);
capabilities.setCapability(MobileCapabilityType.DEVICE_NAME, appiumInit.DEVICE_NAME);
capabilities.setCapability(MobileCapabilityType.AUTOMATION_NAME, appiumInit.AUTOMATION_NAME);
capabilities.setCapability(MobileCapabilityType.NEW_COMMAND_TIMEOUT, appiumInit.NEW_COMMAND_TIMEOUT);
capabilities.setCapability(MobileCapabilityType.UDID, appiumInit.UDID);
capabilities.setCapability(MobileCapabilityType.APP, appiumInit.APPLICATION_PATH);

	//	capabilities.setCapability(MobileCapabilityType.PLATFORM_VERSION, appiumInit.PLATFORM_VERSION);
	//	capabilities.setCapability("clearSystemFiles", true);
	//capabilities.setCapability("autoWebView", true);
	//capabilities.setCapability("recreateChromeDriverSessions", true);
	//capabilities.setCapability("chromedriverExecutable", "/Users/42211/Documents/SlaterAutomation/chromedriver/chromedriver");
	capabilities.setCapability("newCommandTimeout", 360000);
	capabilities.setCapability("appPackage",appiumInit.BUNDLEID);
	capabilities.setCapability("appActivity",appiumInit.APP_ACTIVITY);
	capabilities.setCapability("SYSTEM_PORT",appiumInit.SYSTEM_PORT);
	capabilities.setCapability("APPIUMPORT",appiumInit.APPIUMPORT);

	//	capabilities.setCapability("skipUnlock",true);
	//		capabilities.setCapability("appActivity",appiumInit.chromedriverExecutable);
	capabilities.setCapability(MobileCapabilityType.NO_RESET, true);
	capabilities.setCapability(MobileCapabilityType.FULL_RESET, false);
	try {
		logAndroidDriverAPI.info("Starting the driver");
		driver = new AndroidDriver(new URL("http://" + appiumInit.SERVERIP + ":" + appiumInit.APPIUMPORT + "/wd/hub"),
				capabilities);
		androidDriver = driver;
		logAndroidDriverAPI.info("Appium started",true);
		
	} catch (Exception e) {
		System.out.println(e);
		driver = null;
	}
	return driver;
}

helllo Jitu thank you for the info, does it work on all version of firetv, I read some post on appium that it will not work on firetv os 5 or something? I am new and much guidance would greatly appreciate thank you.

When i tried it was not working for some versions

Thank you for replying, which framework are you using? Mocha? Thank you

Were you able to use the same desired capabilities in Appium desktop. Thank you in advance!