systelab-components-wdio-test
Version:
Widgets to be use in the E2E Tests based in WDIO
20 lines (19 loc) • 501 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Switch = void 0;
const button_js_1 = require("./button.js");
class Switch extends button_js_1.Button {
async isChecked() {
return this.byCSS("input").isSelected();
}
async isEnabled() {
return this.byCSS("input").isEnabled();
}
async isDisabled() {
return !(await this.isEnabled());
}
async toggle() {
return this.click();
}
}
exports.Switch = Switch;