I wrote a simple Java-TestNG project in which the desired capabilities are
{
URL url = new URL("http://127.0.0.1:4724/wd/hub");
DesiredCapabilities caps = new DesiredCapabilities();
caps.setCapability(MobileCapabilityType.PLATFORM_NAME, "ANDROID");
caps.setCapability("appPackage", "com.xxx.xyz");
caps.setCapability("appActivity", "com.xxx.xyz.xyzActivity");
driver = new AppiumDriver(url,caps);
System.out.println("Application started");
}
But when I used the same in Appium Inspector,
{
"platformName": "Android",
"appPackage": "com.xxx.xyz",
"appActivity": "com.xxx.xyz.xyzActivity"
}
I am getting pop up with this text
Invalid or unsupported WebDriver capabilities found ("appPackage", "appActivity"). Ensure to only use valid W3C WebDriver capabilities
The problem got resolved when I entered the same configuration as in the Java-TestNG program in to Appium Inspector, which is
The Appium Inspector started working fine. Some how Appium Inspector did not like this configuration,