3

TL;DR: When I have an emulator open, and I try to call the browser using Appium, I get an error saying that the browser isn't callable, even though there is a browser in the device. Not sure what it's called, so I can call it in Desired Capabilities.

Long story long: I'm new to Appium so trying to get a basic emulator session going. I'm new to Java too, but I'm not using Java here and the Appium site video didn't require Java to get a basic session going, so this isn't a "your code is rubbish" Java issue. (Video link I watched: https://youtu.be/IOSUBda2-g4, though this didnt' call a browser on the device so wasn't a helpful guide for newbies like me).

On Win10, I installed Appium Desktop for Windows (current version 1.2.0 beta). I have Android Studio installed (v2.3.3), and an image for a Pixel device.

I open Android Studio > Tools > Android > AVD Manager > Pixel API 25 (which is set up using Android 7.1.1 and API 25) and I start the emulator. The emulator opens, and the first thing I see is "Photos has stopped Close app" and an X. Somewhat worrying but hey, I installed the image from AVD Manager so I got what I got.

If I then go to Appium Desktop (host 0.0.0.0, port 4723) and start the server (v1.6.5), I get the console. I click Start New Session, and the settings screen comes up. I am on the Automatic Server tab. I go to Saved capabilities tab. I have these settings saved:

{
  "platformName": "Android",
  "deviceName": "Android Emulator",
  "browserName": "Browser",
  "avd": "Pixel_API_25",
  "platformVersion": "7.1.1",
  "": "" 
}

NOTE: The last empty entry is because the delete button on Appium for the Desired Capabilities has no effect in this version of Appium Desktop.

I click "Start session" in Appium Desktop.

Since the emulator is already started, I get error "An unknown server-side error occurred while processing the command. Original error: Could not find package com.android.browser on the device"

There is a very simple browser on the Pixel phone, but I can't invoke it because I don't know what it is called. There is no Chrome or Firefox installed by default. If I go on the device I can run a Google search in this basic browser, but I don't know what it is called to try to invoke it from Appium.

I'm trying to use the guidance in https://github.com/appium/appium/blob/master/docs/en/writing-running-appium/caps.md but I'm lost, and trying stuff with no success.

QUESTION: What is the browser called so I can invoke it?

Why am I trying to do this? I actually wanted to invoke a basic Calculator.apk that I have locally, but that didn't work either (it never started when I specified "app": "C:\android\Calculator.apk"), so I thought I should start with a basic browser session rather than APKs.

I tried the same as above with API 26 but that didn't work either. I haven't solved the APK invoke issue, but that's likely another issue.

Any assistance with the DCs much appreciated.

Mike

0 Answers0