Skip to content
This repository has been archived by the owner on Mar 20, 2024. It is now read-only.

Unable to click or tap on button using appium driver #335

Open
cpintea opened this issue Sep 3, 2018 · 0 comments
Open

Unable to click or tap on button using appium driver #335

cpintea opened this issue Sep 3, 2018 · 0 comments

Comments

@cpintea
Copy link

cpintea commented Sep 3, 2018

I have this configuration which starts the android emulators and load the url in chrome.
androidEmulator:
autoload:
'': %paths.base%/bootstrap/
extensions:
Behat\MinkExtension:
base_url: http://google.com
javascript_session: 'foo'
sessions:
foo:
appium:
browser: "Chrome"
appium_host: "http://127.0.0.1"
appium_port: "4723"
# use chrome browser
# browser capabilities
capabilities: {"platformName": "Android", "deviceName": "Android Emulator", "browser": "Chrome", "avd": "NexusSAPI28", "noReset": false}
suites: # list of test suites available for current profile ("default" in this case)
default: # this suite is called "default"
paths: # check these paths
features: %paths.base%/Features
bootstrap: %paths.base%/Android/bootstrap/
contexts: # use these contexts (test suites)
- FeatureContextAndroid: # FeatureContext class"
- Behat\MinkExtension\Context\RawMinkContext

The step implementation:
$session = $this->getSession();
$element=$session->getDriver()->find("$xpath") => return null every time.
It is possible to use the configuration above and identify elements in a Chrome browser on an android device?
If i use directly "facebook/php-webdriver" to initialize the driver i can access the page element with
$drv=self::createDriver();
$drv->get($url);
$element = $drv->findElements(WebDriverBy::partialLinkText("FRANÇAIS"));

For me it look like the AppiumFactory.php implementation in MinkExtension have no functionality to search elements on mobile devices.

Or , maybe i am on wrong path here. Any ideas how to use the MinkExtension (appium) to be able to identify elements on chrome (Android)?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant