@sap_oss/wdio-qmate-service 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/{test/core/package-lock.json → docs/bestPractices/spec.md} +0 -0
- package/docs/doc.md +176 -353
- package/docs/gettingStarted/setup.md +2 -2
- package/docs/index.md +1 -1
- package/docs/sections/bestPractices/authentication.md +151 -0
- package/docs/sections/bestPractices/dataHandling.md +61 -0
- package/docs/sections/bestPractices/selectors.md +44 -0
- package/docs/{contact.md → sections/contact.md} +0 -0
- package/docs/sections/features/advancedDataHandling.md +252 -0
- package/docs/sections/features/config.md +171 -0
- package/docs/sections/features/dataHandling.md +83 -0
- package/docs/{gettingStarted → sections/features}/selectors.md +0 -0
- package/docs/sections/features/spec.md +0 -0
- package/docs/sections/gettingStarted/config.md +18 -0
- package/docs/sections/gettingStarted/execution.md +7 -0
- package/docs/sections/gettingStarted/setup.md +9 -0
- package/docs/sections/gettingStarted/spec.md +31 -0
- package/docs/sections/gettingStarted/specs.md +19 -0
- package/docs/sections/support/bugReporting.md +19 -0
- package/docs/sections/support/knownIssuesAndLimitations.md +0 -0
- package/docs/sections/support/troubleshooting.md +16 -0
- package/docs/sources/images/fiori_form.PNG +0 -0
- package/docs/sources/images/sapCloud_form.PNG +0 -0
- package/lib/index.js +59 -82
- package/lib/index.js.map +1 -1
- package/lib/reuse/authenticator/authHandler.js +12 -23
- package/lib/reuse/authenticator/authHandler.js.map +1 -1
- package/lib/reuse/authenticator/basicUrlAuthenticator.js +21 -32
- package/lib/reuse/authenticator/basicUrlAuthenticator.js.map +1 -1
- package/lib/reuse/authenticator/customAuthenticator.js +42 -55
- package/lib/reuse/authenticator/customAuthenticator.js.map +1 -1
- package/lib/reuse/authenticator/formAuthenticator.js +37 -50
- package/lib/reuse/authenticator/formAuthenticator.js.map +1 -1
- package/lib/reuse/authenticator/plainAuthenticator.js +5 -16
- package/lib/reuse/authenticator/plainAuthenticator.js.map +1 -1
- package/lib/reuse/helper/jsDocGen.js +4 -12
- package/lib/reuse/helper/jsDocGen.js.map +1 -1
- package/lib/reuse/index.js +20 -5
- package/lib/reuse/index.js.map +1 -1
- package/lib/reuse/modules/common/navigation.js +10 -23
- package/lib/reuse/modules/common/navigation.js.map +1 -1
- package/lib/reuse/modules/common/userInteraction.js +40 -73
- package/lib/reuse/modules/common/userInteraction.js.map +1 -1
- package/lib/reuse/modules/nonUi5/assertion.js +31 -52
- package/lib/reuse/modules/nonUi5/assertion.js.map +1 -1
- package/lib/reuse/modules/nonUi5/element.js +266 -331
- package/lib/reuse/modules/nonUi5/element.js.map +1 -1
- package/lib/reuse/modules/nonUi5/navigation.js +10 -21
- package/lib/reuse/modules/nonUi5/navigation.js.map +1 -1
- package/lib/reuse/modules/nonUi5/userInteraction.js +176 -215
- package/lib/reuse/modules/nonUi5/userInteraction.js.map +1 -1
- package/lib/reuse/modules/service/odata.d.ts +106 -94
- package/lib/reuse/modules/service/odata.js +209 -204
- package/lib/reuse/modules/service/odata.js.map +1 -1
- package/lib/reuse/modules/service/rest.js +64 -81
- package/lib/reuse/modules/service/rest.js.map +1 -1
- package/lib/reuse/modules/ui5/assertion.js +217 -268
- package/lib/reuse/modules/ui5/assertion.js.map +1 -1
- package/lib/reuse/modules/ui5/confirmationDialog.js +17 -42
- package/lib/reuse/modules/ui5/confirmationDialog.js.map +1 -1
- package/lib/reuse/modules/ui5/control.js +12 -33
- package/lib/reuse/modules/ui5/control.js.map +1 -1
- package/lib/reuse/modules/ui5/date.js +70 -89
- package/lib/reuse/modules/ui5/date.js.map +1 -1
- package/lib/reuse/modules/ui5/element.js +121 -156
- package/lib/reuse/modules/ui5/element.js.map +1 -1
- package/lib/reuse/modules/ui5/errorDialog.js +4 -17
- package/lib/reuse/modules/ui5/errorDialog.js.map +1 -1
- package/lib/reuse/modules/ui5/footerBar.js +28 -63
- package/lib/reuse/modules/ui5/footerBar.js.map +1 -1
- package/lib/reuse/modules/ui5/mockserver.js +390 -427
- package/lib/reuse/modules/ui5/mockserver.js.map +1 -1
- package/lib/reuse/modules/ui5/navigation.js +105 -132
- package/lib/reuse/modules/ui5/navigation.js.map +1 -1
- package/lib/reuse/modules/ui5/navigationBar.js +58 -77
- package/lib/reuse/modules/ui5/navigationBar.js.map +1 -1
- package/lib/reuse/modules/ui5/qunit.js +16 -27
- package/lib/reuse/modules/ui5/qunit.js.map +1 -1
- package/lib/reuse/modules/ui5/session.js +200 -236
- package/lib/reuse/modules/ui5/session.js.map +1 -1
- package/lib/reuse/modules/ui5/table.js +79 -98
- package/lib/reuse/modules/ui5/table.js.map +1 -1
- package/lib/reuse/modules/ui5/userInteraction.js +264 -335
- package/lib/reuse/modules/ui5/userInteraction.js.map +1 -1
- package/lib/reuse/modules/util/browser.js +131 -178
- package/lib/reuse/modules/util/browser.js.map +1 -1
- package/lib/reuse/modules/util/data.js +3 -2
- package/lib/reuse/modules/util/data.js.map +1 -1
- package/lib/reuse/modules/util/file.js +71 -90
- package/lib/reuse/modules/util/file.js.map +1 -1
- package/lib/reuse/modules/util/function.js +68 -87
- package/lib/reuse/modules/util/function.js.map +1 -1
- package/lib/reuse/modules/util/system.js +22 -33
- package/lib/reuse/modules/util/system.js.map +1 -1
- package/lib/scripts/dataExchange/dataExchange.js +145 -160
- package/lib/scripts/dataExchange/dataExchange.js.map +1 -1
- package/lib/scripts/dataExchange/dataExchangeUtil.js +93 -114
- package/lib/scripts/dataExchange/dataExchangeUtil.js.map +1 -1
- package/lib/scripts/hooks/after.js +3 -14
- package/lib/scripts/hooks/after.js.map +1 -1
- package/lib/scripts/hooks/before.js +9 -20
- package/lib/scripts/hooks/before.js.map +1 -1
- package/lib/scripts/hooks/beforeSession.js +7 -18
- package/lib/scripts/hooks/beforeSession.js.map +1 -1
- package/lib/scripts/hooks/onComplete.js +2 -13
- package/lib/scripts/hooks/onComplete.js.map +1 -1
- package/lib/scripts/hooks/onPrepare.js +9 -20
- package/lib/scripts/hooks/onPrepare.js.map +1 -1
- package/lib/scripts/hooks/utils/addLocatorCommands.js +109 -172
- package/lib/scripts/hooks/utils/addLocatorCommands.js.map +1 -1
- package/lib/scripts/hooks/utils/browserLog.js +18 -31
- package/lib/scripts/hooks/utils/browserLog.js.map +1 -1
- package/lib/scripts/hooks/utils/dataExchangeCommands.js +13 -24
- package/lib/scripts/hooks/utils/dataExchangeCommands.js.map +1 -1
- package/lib/scripts/hooks/utils/decryption.d.ts +1 -1
- package/lib/scripts/hooks/utils/decryption.js +33 -14
- package/lib/scripts/hooks/utils/decryption.js.map +1 -1
- package/lib/scripts/hooks/utils/lib.js +249 -272
- package/lib/scripts/hooks/utils/lib.js.map +1 -1
- package/lib/scripts/hooks/utils/locatorCommands.js +154 -183
- package/lib/scripts/hooks/utils/locatorCommands.js.map +1 -1
- package/mkdocs.yml +16 -3
- package/package.json +14 -11
- package/test/authenticator/staticLogin/specs/custom.spec.js +30 -1
- package/test/reuse/nonUi5/element/getById.spec.js +17 -0
- package/test/reuse/service/odata/get.spec.js +61 -0
- package/test/reuse/service/odata/getEntitySet.spec.js +87 -0
- package/test/reuse/service/odata/test.odata.conf.js +15 -0
- package/test/reuse/ui5/confirmationDialog/clickButton.spec.js +87 -0
- package/test/reuse/ui5/confirmationDialog/test.confirmationDialog.conf.js +2 -1
- package/test/reuse/ui5/element/test.element.conf.js +2 -1
- package/test/reuse/ui5/element/waitForAll.spec.js +46 -0
- package/test/reuse/ui5/userInteraction/clearAndFillSmartFieldInputAndRetry.spec.js +28 -0
- package/test/reuse/ui5/userInteraction/test.userInteraction.conf.js +1 -0
- package/test/reuse/util/browser/switchToNewWindow.spec.js +2 -2
- package/test/reuse/util/console/console.spec.js +27 -0
- package/test/reuse/util/console/test.console.conf.js +12 -0
- package/test/reuse/util/data/data/test.secure.json +7 -3
- package/test/reuse/util/data/getSecureData.spec.js +9 -3
- package/test/reuse/util/file/pdfParser.spec.js +33 -8
- package/test/reuse/util/system/system.spec.js +16 -0
- package/test/reuse/util/system/test.system.conf.js +12 -0
- package/tsconfig.json +1 -1
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
3
|
exports.QUnit = void 0;
|
|
13
4
|
/**
|
|
@@ -25,24 +16,22 @@ class QUnit {
|
|
|
25
16
|
* @param {String} path - Relative path to the QUnit/OPA5 html file.
|
|
26
17
|
* @example await ui5.qunit.executeTests("path/to/qunit.html");
|
|
27
18
|
*/
|
|
28
|
-
executeTests(path) {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
throw new Error("QUnit tests failed, see log message for more details.");
|
|
45
|
-
});
|
|
19
|
+
async executeTests(path) {
|
|
20
|
+
const url = await browser.getUrl();
|
|
21
|
+
if (url.indexOf("4431") !== -1) {
|
|
22
|
+
await browser.navigateTo(`http://localhost:4431/${path}`);
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
await browser.navigateTo(`http://localhost:34005/${path}`);
|
|
26
|
+
}
|
|
27
|
+
// Note: cannot use "null" as a first argument for "clientsidescripts.waitForAngular" due to browser.executeAsync error:
|
|
28
|
+
// "Error: Malformed type for "args" parameter of command executeAsyncScript
|
|
29
|
+
// Expected: (string|object|number|boolean|undefined)[]
|
|
30
|
+
// Actual: (null,number)[]"
|
|
31
|
+
await browser.executeAsync(this.clientsidescripts.waitForAngular, undefined, 10);
|
|
32
|
+
const execRes = await browser.executeAsync(this.clientsidescripts.execQUnits, {});
|
|
33
|
+
if (!execRes)
|
|
34
|
+
throw new Error("QUnit tests failed, see log message for more details.");
|
|
46
35
|
}
|
|
47
36
|
;
|
|
48
37
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"qunit.js","sourceRoot":"","sources":["../../../../src/reuse/modules/ui5/qunit.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC
|
|
1
|
+
{"version":3,"file":"qunit.js","sourceRoot":"","sources":["../../../../src/reuse/modules/ui5/qunit.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;AACb;;;GAGG;AACH,MAAa,KAAK;IAAlB;QAEU,sBAAiB,GAAG,OAAO,CAAC,mCAAmC,CAAC,CAAC;IAyB3E,CAAC;IAvBC;;;;;;OAMG;IACH,KAAK,CAAC,YAAY,CAAE,IAAY;QAC9B,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,MAAM,EAAE,CAAC;QACnC,IAAI,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE;YAC9B,MAAM,OAAO,CAAC,UAAU,CAAC,yBAAyB,IAAI,EAAE,CAAC,CAAC;SAC3D;aAAM;YACL,MAAM,OAAO,CAAC,UAAU,CAAC,0BAA0B,IAAI,EAAE,CAAC,CAAC;SAC5D;QACD,wHAAwH;QACxH,4EAA4E;QAC5E,uDAAuD;QACvD,2BAA2B;QAC3B,MAAM,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,iBAAiB,CAAC,cAAc,EAAE,SAAS,EAAE,EAAE,CAAC,CAAC;QACjF,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,iBAAiB,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;QAClF,IAAI,CAAC,OAAO;YAAE,MAAM,IAAI,KAAK,CAAC,uDAAuD,CAAC,CAAC;IACzF,CAAC;IAAA,CAAC;CAEH;AA3BD,sBA2BC;AAAA,CAAC;AACF,kBAAe,IAAI,KAAK,EAAE,CAAC"}
|
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
3
|
exports.Session = void 0;
|
|
13
4
|
/**
|
|
@@ -27,51 +18,47 @@ class Session {
|
|
|
27
18
|
* @example await ui5.session.login("PURCHASER");
|
|
28
19
|
* @example await ui5.session.login("JOHN_DOE", "abc123!", true);
|
|
29
20
|
*/
|
|
30
|
-
login(username, password = "Welcome1!", verify = false, timeout = process.env.QMATE_CUSTOM_TIMEOUT || 30000) {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
throw new Error("login failed. Could not find the login page within the given time. \n" + error);
|
|
72
|
-
}
|
|
73
|
-
yield this._loginWithUsernameAndPassword(username, password, authenticator, verify, messageSelector);
|
|
74
|
-
});
|
|
21
|
+
async login(username, password = "Welcome1!", verify = false, timeout = process.env.QMATE_CUSTOM_TIMEOUT || 30000) {
|
|
22
|
+
if (browser.config && browser.config.params &&
|
|
23
|
+
browser.config.params.auth && browser.config.params.auth.formType === "skip") {
|
|
24
|
+
util.console.warn("Login is skipped since 'formType' is set to 'skip'");
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
if (!username) {
|
|
28
|
+
throw new Error("Please provide a valid username.");
|
|
29
|
+
}
|
|
30
|
+
let authenticator;
|
|
31
|
+
let messageSelector;
|
|
32
|
+
try {
|
|
33
|
+
await browser.waitUntil(async function () {
|
|
34
|
+
try {
|
|
35
|
+
const fioriFormId = ui5.authenticators.fioriForm.formId;
|
|
36
|
+
const elem = await nonUi5.element.getByCss(fioriFormId, 0, 7500);
|
|
37
|
+
await nonUi5.element.isVisible(elem);
|
|
38
|
+
authenticator = ui5.authenticators.fioriForm;
|
|
39
|
+
messageSelector = ui5.authenticators.fioriForm.messageSelector;
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
catch (e) {
|
|
43
|
+
// continue
|
|
44
|
+
}
|
|
45
|
+
try {
|
|
46
|
+
const sapCloudFormId = ui5.authenticators.sapCloudForm.formId;
|
|
47
|
+
const elem = await nonUi5.element.getByCss(sapCloudFormId, 0, 7500);
|
|
48
|
+
await nonUi5.element.isVisible(elem);
|
|
49
|
+
authenticator = ui5.authenticators.sapCloudForm;
|
|
50
|
+
messageSelector = ui5.authenticators.sapCloudForm.messageSelector;
|
|
51
|
+
return true;
|
|
52
|
+
}
|
|
53
|
+
catch (e) {
|
|
54
|
+
return false;
|
|
55
|
+
}
|
|
56
|
+
}, timeout);
|
|
57
|
+
}
|
|
58
|
+
catch (error) {
|
|
59
|
+
throw new Error("login failed. Could not find the login page within the given time. \n" + error);
|
|
60
|
+
}
|
|
61
|
+
await this._loginWithUsernameAndPassword(username, password, authenticator, verify, messageSelector);
|
|
75
62
|
}
|
|
76
63
|
;
|
|
77
64
|
/**
|
|
@@ -83,20 +70,18 @@ class Session {
|
|
|
83
70
|
* @param {Boolean} [verify=false] - Specifies if the function will check the shell header after logging in.
|
|
84
71
|
* @example await ui5.session.loginFiori("john", "abc123!");
|
|
85
72
|
*/
|
|
86
|
-
loginFiori(username, password = "Welcome1!", verify = false) {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}
|
|
99
|
-
});
|
|
73
|
+
async loginFiori(username, password = "Welcome1!", verify = false) {
|
|
74
|
+
if (!username) {
|
|
75
|
+
throw new Error("Please provide a valid username.");
|
|
76
|
+
}
|
|
77
|
+
try {
|
|
78
|
+
const authenticator = ui5.authenticators.fioriForm;
|
|
79
|
+
const messageSelector = ui5.authenticators.fioriForm.messageSelector;
|
|
80
|
+
return await this._loginWithUsernameAndPassword(username, password, authenticator, verify, messageSelector);
|
|
81
|
+
}
|
|
82
|
+
catch (error) {
|
|
83
|
+
throw new Error(`Function 'loginFiori' failed: ${error}`);
|
|
84
|
+
}
|
|
100
85
|
}
|
|
101
86
|
;
|
|
102
87
|
/**
|
|
@@ -108,20 +93,18 @@ class Session {
|
|
|
108
93
|
* @param {Boolean} [verify=false] - Specifies if the function will check the shell header after logging in.
|
|
109
94
|
* @example await ui5.session.loginSapCloud("john", "abc123!");
|
|
110
95
|
*/
|
|
111
|
-
loginSapCloud(username, password = "Welcome1!", verify = false) {
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
}
|
|
124
|
-
});
|
|
96
|
+
async loginSapCloud(username, password = "Welcome1!", verify = false) {
|
|
97
|
+
if (!username) {
|
|
98
|
+
throw new Error("Please provide a valid username.");
|
|
99
|
+
}
|
|
100
|
+
try {
|
|
101
|
+
const authenticator = await ui5.authenticators.sapCloudForm;
|
|
102
|
+
const messageSelector = ui5.authenticators.sapCloudForm.messageSelector;
|
|
103
|
+
return await this._loginWithUsernameAndPassword(username, password, authenticator, verify, messageSelector);
|
|
104
|
+
}
|
|
105
|
+
catch (error) {
|
|
106
|
+
throw new Error(`Function 'loginSapCloud' failed: ${error}`);
|
|
107
|
+
}
|
|
125
108
|
}
|
|
126
109
|
;
|
|
127
110
|
/**
|
|
@@ -136,23 +119,21 @@ class Session {
|
|
|
136
119
|
* @param {Boolean} [verify=false] - Specifies if the function will check the shell header after logging in.
|
|
137
120
|
* @example await ui5.session.loginCustom("JOHN_DOE", "abc123!", "#username", #password, "#logon");
|
|
138
121
|
*/
|
|
139
|
-
loginCustom(username, password = "Welcome1!", usernameFieldSelector, passwordFieldSelector, logonButtonSelector, verify = false) {
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
}
|
|
155
|
-
});
|
|
122
|
+
async loginCustom(username, password = "Welcome1!", usernameFieldSelector, passwordFieldSelector, logonButtonSelector, verify = false) {
|
|
123
|
+
if (!username) {
|
|
124
|
+
throw new Error("Please provide a valid username.");
|
|
125
|
+
}
|
|
126
|
+
try {
|
|
127
|
+
const authenticator = {
|
|
128
|
+
"usernameFieldSelector": usernameFieldSelector,
|
|
129
|
+
"passwordFieldSelector": passwordFieldSelector,
|
|
130
|
+
"logonButtonSelector": logonButtonSelector
|
|
131
|
+
};
|
|
132
|
+
return await this._loginWithUsernameAndPassword(username, password, authenticator, verify);
|
|
133
|
+
}
|
|
134
|
+
catch (error) {
|
|
135
|
+
throw new Error(`Function 'loginCustom' failed: ${error}`);
|
|
136
|
+
}
|
|
156
137
|
}
|
|
157
138
|
;
|
|
158
139
|
/**
|
|
@@ -185,39 +166,37 @@ class Session {
|
|
|
185
166
|
// spec
|
|
186
167
|
await ui5.session.loginCustomViaConfig();
|
|
187
168
|
*/
|
|
188
|
-
loginCustomViaConfig(username, password = "Welcome1!", verify = false) {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
util.console.info("\x1b[33m%s\x1b[0m", "Login credentials will be taken from config.");
|
|
201
|
-
}
|
|
202
|
-
else if (!username && !password) {
|
|
203
|
-
throw new Error("Username or password is missing. Check your parameters or config file.");
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
catch (error) {
|
|
207
|
-
throw new Error("Function 'loginCustomViaConfig' failed: Please maintain the credentials in your config or spec.: " + error);
|
|
208
|
-
}
|
|
209
|
-
try {
|
|
210
|
-
const authenticator = {
|
|
211
|
-
"usernameFieldSelector": browser.config.params.auth.usernameFieldSelector,
|
|
212
|
-
"passwordFieldSelector": browser.config.params.auth.passwordFieldSelector,
|
|
213
|
-
"logonButtonSelector": browser.config.params.auth.logonButtonSelector
|
|
214
|
-
};
|
|
215
|
-
return yield this._loginWithUsernameAndPassword(username, password, authenticator, verify);
|
|
169
|
+
async loginCustomViaConfig(username, password = "Welcome1!", verify = false) {
|
|
170
|
+
try {
|
|
171
|
+
const baseUrl = browser.config.baseUrl;
|
|
172
|
+
await browser.navigateTo(baseUrl);
|
|
173
|
+
if (browser.config.params &&
|
|
174
|
+
browser.config.params.auth &&
|
|
175
|
+
browser.config.params.auth.username &&
|
|
176
|
+
browser.config.params.auth.password) {
|
|
177
|
+
username = browser.config.params.auth.username;
|
|
178
|
+
password = browser.config.params.auth.password;
|
|
179
|
+
// @ts-ignore
|
|
180
|
+
util.console.info("\x1b[33m%s\x1b[0m", "Login credentials will be taken from config.");
|
|
216
181
|
}
|
|
217
|
-
|
|
218
|
-
throw new Error("
|
|
182
|
+
else if (!username && !password) {
|
|
183
|
+
throw new Error("Username or password is missing. Check your parameters or config file.");
|
|
219
184
|
}
|
|
220
|
-
}
|
|
185
|
+
}
|
|
186
|
+
catch (error) {
|
|
187
|
+
throw new Error("Function 'loginCustomViaConfig' failed: Please maintain the credentials in your config or spec.: " + error);
|
|
188
|
+
}
|
|
189
|
+
try {
|
|
190
|
+
const authenticator = {
|
|
191
|
+
"usernameFieldSelector": browser.config.params.auth.usernameFieldSelector,
|
|
192
|
+
"passwordFieldSelector": browser.config.params.auth.passwordFieldSelector,
|
|
193
|
+
"logonButtonSelector": browser.config.params.auth.logonButtonSelector
|
|
194
|
+
};
|
|
195
|
+
return await this._loginWithUsernameAndPassword(username, password, authenticator, verify);
|
|
196
|
+
}
|
|
197
|
+
catch (error) {
|
|
198
|
+
throw new Error("Function 'loginCustomViaConfig' failed. Please maintain the auth values in your config.");
|
|
199
|
+
}
|
|
221
200
|
}
|
|
222
201
|
;
|
|
223
202
|
// =================================== LOGOUT / SWITCH ===================================
|
|
@@ -229,21 +208,19 @@ class Session {
|
|
|
229
208
|
* Set this to false if the system does not show the text after logging out.
|
|
230
209
|
* @example await ui5.session.logout();
|
|
231
210
|
*/
|
|
232
|
-
logout(verify = true) {
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
}
|
|
246
|
-
});
|
|
211
|
+
async logout(verify = true) {
|
|
212
|
+
if (browser.config && browser.config.params &&
|
|
213
|
+
browser.config.params.auth && browser.config.params.auth.formType === "skip") {
|
|
214
|
+
console.warn("Logout is skipped.");
|
|
215
|
+
await browser.reloadSession(); // Clean cache
|
|
216
|
+
return true;
|
|
217
|
+
}
|
|
218
|
+
await ui5.navigationBar.clickUserIcon();
|
|
219
|
+
await this._clickSignOut();
|
|
220
|
+
await ui5.confirmationDialog.clickOk();
|
|
221
|
+
if (verify) {
|
|
222
|
+
await ui5.session.expectLogoutText();
|
|
223
|
+
}
|
|
247
224
|
}
|
|
248
225
|
;
|
|
249
226
|
/**
|
|
@@ -258,18 +235,16 @@ class Session {
|
|
|
258
235
|
* @example const authenticator = ui5.authenticators.fioriForm;
|
|
259
236
|
* await ui5.session.switchUser("PURCHASER", "Welcome1!", authenticator, 30000);
|
|
260
237
|
*/
|
|
261
|
-
switchUser(username, password = "Welcome1!", authenticator, wait = 10000) {
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
}
|
|
272
|
-
});
|
|
238
|
+
async switchUser(username, password = "Welcome1!", authenticator, wait = 10000) {
|
|
239
|
+
await this.logout();
|
|
240
|
+
await util.browser.sleep(wait);
|
|
241
|
+
await browser.navigateTo(browser.config.baseUrl);
|
|
242
|
+
if (!authenticator) {
|
|
243
|
+
this.login(username, password);
|
|
244
|
+
}
|
|
245
|
+
else {
|
|
246
|
+
await this._loginWithUsernameAndPassword(username, password, authenticator);
|
|
247
|
+
}
|
|
273
248
|
}
|
|
274
249
|
;
|
|
275
250
|
// =================================== ASSERTION ===================================
|
|
@@ -280,92 +255,81 @@ class Session {
|
|
|
280
255
|
* This is essential for chaining scripts, so that no static browser sleep in the spec itself is required anymore.
|
|
281
256
|
* @example await ui5.session.expectLogoutText();
|
|
282
257
|
*/
|
|
283
|
-
expectLogoutText() {
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
yield nonUi5.assertion.expectToBeVisible(elem);
|
|
287
|
-
});
|
|
258
|
+
async expectLogoutText() {
|
|
259
|
+
const elem = await nonUi5.element.getById("msgText");
|
|
260
|
+
await nonUi5.assertion.expectToBeVisible(elem);
|
|
288
261
|
}
|
|
289
262
|
;
|
|
290
263
|
// =================================== HELPER ===================================
|
|
291
|
-
_loginWithUsernameAndPassword(username, password = "Welcome1!", authenticator = ui5.authenticators.fioriForm, verify = false, messageSelector) {
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
264
|
+
async _loginWithUsernameAndPassword(username, password = "Welcome1!", authenticator = ui5.authenticators.fioriForm, verify = false, messageSelector) {
|
|
265
|
+
let usernameField = null;
|
|
266
|
+
let passwordField = null;
|
|
267
|
+
let logonField = null;
|
|
268
|
+
try {
|
|
269
|
+
await browser.waitUntil(async function () {
|
|
270
|
+
usernameField = await $(authenticator.usernameFieldSelector);
|
|
271
|
+
passwordField = await $(authenticator.passwordFieldSelector);
|
|
272
|
+
logonField = await $(authenticator.logonButtonSelector);
|
|
273
|
+
return await usernameField.isDisplayedInViewport() &&
|
|
274
|
+
await passwordField.isDisplayedInViewport() &&
|
|
275
|
+
// eslint-disable-next-line no-return-await
|
|
276
|
+
await logonField.isDisplayedInViewport();
|
|
277
|
+
}, {
|
|
278
|
+
timeout: 30000,
|
|
279
|
+
timeoutMsg: "Login failed: Login page with the given authenticator not present."
|
|
280
|
+
});
|
|
281
|
+
// @ts-ignore
|
|
282
|
+
await usernameField.setValue(username);
|
|
283
|
+
// @ts-ignore
|
|
284
|
+
await passwordField.setValue(password);
|
|
285
|
+
// @ts-ignore
|
|
286
|
+
await logonField.click();
|
|
287
|
+
}
|
|
288
|
+
catch (error) {
|
|
289
|
+
throw new Error(`Login failed: Please check if you are already logged in or if the system is down \n. ${error}`);
|
|
290
|
+
}
|
|
291
|
+
if (messageSelector) {
|
|
292
|
+
await this._checkForErrors(messageSelector);
|
|
293
|
+
}
|
|
294
|
+
if (verify) {
|
|
295
|
+
await ui5.navigationBar.expectShellHeader();
|
|
296
|
+
}
|
|
297
|
+
try {
|
|
298
|
+
await util.browser.logUI5Version();
|
|
299
|
+
}
|
|
300
|
+
catch (error) {
|
|
301
|
+
if (error instanceof Error) {
|
|
302
|
+
util.console.warn(error.toString());
|
|
324
303
|
}
|
|
325
|
-
|
|
326
|
-
yield ui5.navigationBar.expectShellHeader();
|
|
327
|
-
}
|
|
328
|
-
try {
|
|
329
|
-
yield util.browser.logUI5Version();
|
|
330
|
-
}
|
|
331
|
-
catch (error) {
|
|
332
|
-
if (error instanceof Error) {
|
|
333
|
-
util.console.warn(error.toString());
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
});
|
|
304
|
+
}
|
|
337
305
|
}
|
|
338
|
-
_clickSignOut() {
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
"
|
|
342
|
-
|
|
343
|
-
"
|
|
344
|
-
"id": "*logoutBtn"
|
|
345
|
-
}
|
|
306
|
+
async _clickSignOut() {
|
|
307
|
+
const selector = {
|
|
308
|
+
"elementProperties": {
|
|
309
|
+
"metadata": "sap.m.StandardListItem",
|
|
310
|
+
"mProperties": {
|
|
311
|
+
"id": "*logoutBtn"
|
|
346
312
|
}
|
|
347
|
-
};
|
|
348
|
-
yield ui5.userInteraction.scrollToElement(selector);
|
|
349
|
-
return ui5.userInteraction.click(selector);
|
|
350
|
-
});
|
|
351
|
-
}
|
|
352
|
-
_checkForErrors(messageSelector) {
|
|
353
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
354
|
-
let uiErrorMessagesFound = false;
|
|
355
|
-
let messageText;
|
|
356
|
-
try {
|
|
357
|
-
const messageDiv = yield nonUi5.element.getByCss(messageSelector, 0, 3000);
|
|
358
|
-
// @ts-ignore
|
|
359
|
-
messageText = yield nonUi5.element.getValue(messageDiv, "text");
|
|
360
|
-
uiErrorMessagesFound = true;
|
|
361
|
-
}
|
|
362
|
-
catch (e) {
|
|
363
|
-
// no error messages found in login
|
|
364
313
|
}
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
314
|
+
};
|
|
315
|
+
await ui5.userInteraction.scrollToElement(selector);
|
|
316
|
+
return ui5.userInteraction.click(selector);
|
|
317
|
+
}
|
|
318
|
+
async _checkForErrors(messageSelector) {
|
|
319
|
+
let uiErrorMessagesFound = false;
|
|
320
|
+
let messageText;
|
|
321
|
+
try {
|
|
322
|
+
const messageDiv = await nonUi5.element.getByCss(messageSelector, 0, 3000);
|
|
323
|
+
// @ts-ignore
|
|
324
|
+
messageText = await nonUi5.element.getValue(messageDiv, "text");
|
|
325
|
+
uiErrorMessagesFound = true;
|
|
326
|
+
}
|
|
327
|
+
catch (e) {
|
|
328
|
+
// no error messages found in login
|
|
329
|
+
}
|
|
330
|
+
if (uiErrorMessagesFound) {
|
|
331
|
+
throw new Error(`Login failed: "${messageText}"`);
|
|
332
|
+
}
|
|
369
333
|
}
|
|
370
334
|
}
|
|
371
335
|
exports.Session = Session;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session.js","sourceRoot":"","sources":["../../../../src/reuse/modules/ui5/session.ts"],"names":[],"mappings":"AAAA,YAAY,C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