Skip to content
This repository was archived by the owner on Jul 29, 2024. It is now read-only.
This repository was archived by the owner on Jul 29, 2024. It is now read-only.

Provide error if locator is not supported by Selenium Server #1632

Closed
@mitchhentges

Description

@mitchhentges

See the issue posted on the Selendroid issue tracker.

I'm running my tests for a hybrid app on an Android tablet. After properly configuring the server's capabilities, I kept running into a StaleElementReferenceException. It turns out that this is because by.model doesn't work with Selendroid.

An error should be provided if a locator is not supported.

To reproduce:

  1. Have a hybrid Android app that uses Angular
  2. Set up configuration
seleniumAddress: 'http://localhost:4444/wd/hub',
capabilities: {
    browserName: 'ANDROID',
    targetPlatform: {androidVersion}, //like 'ANDROID19'
    aut: {applicationId}
},

onPrepare: function() {
    var wd = require('wd'),
        protractor = require('protractor'),
        wdBridge = require('wd-bridge')(protractor, wd);
    wdBridge.initFromProtractor(exports.config);
    wdBrowser.context('WEBVIEW');
},
  1. As part of the test, locate an element by.model(...) and then attempt to do sendKeys(...).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions