Samsung has released a possible way to start a naive browser (Internet)
Although the code cannot be run directly, somehow I managed to start the naive browser on a real device in “Naive app” mode. But when I try to switch to webview context, the browser exits (like pressing the home button) and appium cannot find the webview within the timeout duration. ( Error: Failed to start Chromedriver session: An unknown server-side error occurred while processing the command. Original error: chrome not reachable)
I wonder if there is some special handling on Samsung naive browser switching webview mode.
I have found some workaround:
One “solution” is to manually or by adb start Samsung naive browser again(or push the app back to front) right after I execute “switch.to.context”, and appium will able to find the webview.
Another “solution” is change the code in “appium-android-driver”, e.g. add a proper information in variable “CHROME_BROWSER_PACKAGE_ACTIVITY”. Then Appium can start the naive browser in “We’re going to run a Chrome-based session” mode.
But personally I don’t like these two “solutions”, it’s a bit too “unofficial” or involving change library.
I wonder if there is a proper way to start an app in “We’re going to run a Chrome-based session”
btw, I am using the latest Appium (1.10.1)