UNPKG

@sap_oss/wdio-qmate-service

Version:

[![REUSE status](https://api.reuse.software/badge/github.com/SAP/wdio-qmate-service)](https://api.reuse.software/info/github.com/SAP/wdio-qmate-service)[![Node.js CI](https://github.com/SAP/wdio-qmate-service/actions/workflows/node.js.yml/badge.svg)](http

51 lines 1.59 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ErrorDialog = void 0; const verboseLogger_1 = require("../../helper/verboseLogger"); /** * @class errorDialog * @memberof ui5 */ class ErrorDialog { vlf = new verboseLogger_1.VerboseLoggerFactory("ui5", "errorDialog"); selectors = { errorDialog: { elementProperties: { metadata: "sap.m.Bar" }, ancestorProperties: { metadata: "sap.m.Dialog", icon: "sap-icon://error" } }, closeButton: { elementProperties: { metadata: "sap.m.Button", text: "Close" } } }; /** * @function expectToBeVisible * @memberOf ui5.errorDialog * @description Expects that the error dialog is visible on the page. * @example await ui5.errorDialog.expectToBeVisible(); */ async expectToBeVisible() { const vl = this.vlf.initLog(this.expectToBeVisible); await ui5.assertion.expectToBeVisible(this.selectors.errorDialog); } /** * @function clickClose * @memberOf ui5.errorDialog * @description Clicks the 'Close' button at the error dialog. * @example await ui5.errorDialog.clickClose(); */ async clickClose() { const vl = this.vlf.initLog(this.clickClose); await ui5.userInteraction.click(this.selectors.closeButton); } } exports.ErrorDialog = ErrorDialog; exports.default = new ErrorDialog(); //# sourceMappingURL=errorDialog.js.map