Extend
Methods
findElementWithAssert
addon/-private/extend/find-element-with-assert.js:38-44
Parameters
pageObjectNodeCeibo Node of the treetargetSelectorstring Specific CSS selectoroptionsObject Additional optionsoptions.resetScopeboolean Do not use inherited scopeoptions.containsstring Filter by using :contains(‘foo’) pseudo-classoptions.lastboolean Filter by using :last pseudo-classoptions.visibleboolean Filter by using :visible pseudo-classoptions.multipleboolean Specify if built selector can match multiple elements.options.testContainerString Context where to search elements in the DOMoptions.atnumber Filter by index using :eq(x) pseudo-classoptions.pageObjectKeyString Used in the error message when the element is not found
Examples
import { findElementWithAssert } from 'ember-cli-page-object/extend';
export default function isDisabled(selector, options = {}) {
return {
isDescriptor: true,
get() {
return findElementWithAssert(this, selector, options).is(':disabled');
}
};
}
Returns Object jQuery object
findElement
addon/-private/extend/find-element.js:36-42
Parameters
pageObjectNodeCeibo Node of the treetargetSelectorstring Specific CSS selectoroptionsObject Additional optionsoptions.resetScopeboolean Do not use inherited scopeoptions.containsstring Filter by using :contains(‘foo’) pseudo-classoptions.atnumber Filter by index using :eq(x) pseudo-classoptions.lastboolean Filter by using :last pseudo-classoptions.visibleboolean Filter by using :visible pseudo-classoptions.multipleboolean Specify if built selector can match multiple elements.options.testContainerString Context where to search elements in the DOM
Examples
import { findElement } from 'ember-cli-page-object/extend';
export default function isDisabled(selector, options = {}) {
return {
isDescriptor: true,
get() {
return findElement(this, selector, options).is(':disabled');
}
};
}
Returns Object jQuery object