froth-webdriverio-framework 3.0.50 → 3.0.52
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/commonMethods/apicall.js +4 -4
- package/config/api.conf.js +65 -16
- package/package.json +1 -1
package/commonMethods/apicall.js
CHANGED
|
@@ -109,16 +109,16 @@ async function validateAttributeData(attribute_name,attribute,buffer, buffername
|
|
|
109
109
|
expect(attribute).toBe(valueToVerify, `${attribute_name} --> Expected value: ${valueToVerify}, but got: ${attribute}`);
|
|
110
110
|
assertionStatus = true; // If assertion passes, set status to true
|
|
111
111
|
|
|
112
|
-
console.log("
|
|
113
|
-
let annotationMessage = `${attribute_name}
|
|
112
|
+
console.log("verification succeeded.");
|
|
113
|
+
let annotationMessage = `${attribute_name} verification passed. Actual text: ${attribute}, Expected text: ${valueToVerify}.`;
|
|
114
114
|
|
|
115
115
|
if (process.env.BROWSERSTACK)
|
|
116
116
|
await amendToBrowserstack(annotationMessage, "info");
|
|
117
117
|
|
|
118
118
|
} catch (e) {
|
|
119
119
|
console.error('Error in validateAttributeData:', e);
|
|
120
|
-
console.log(`${attribute_name}
|
|
121
|
-
let annotationMessage = `${attribute_name}
|
|
120
|
+
console.log(`${attribute_name} verification failed. Expected text: ${valueToVerify}.`);
|
|
121
|
+
let annotationMessage = `${attribute_name} verification failed. Expected text: ${valueToVerify}.`;
|
|
122
122
|
|
|
123
123
|
if (process.env.BROWSERSTACK)
|
|
124
124
|
await amendToBrowserstack(annotationMessage, "error");
|
package/config/api.conf.js
CHANGED
|
@@ -1,28 +1,77 @@
|
|
|
1
1
|
const deepmerge = require('deepmerge')
|
|
2
|
-
process.env.BROWSERSTACK =
|
|
2
|
+
process.env.BROWSERSTACK = true;
|
|
3
3
|
const commonmobileconfig = require('./common.mobile.conf');
|
|
4
4
|
|
|
5
5
|
const apiconfig = deepmerge.all([commonmobileconfig, {
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
7
|
+
|
|
8
|
+
services: [
|
|
9
|
+
['browserstack', {
|
|
10
|
+
|
|
11
|
+
browserstackLocal: process.env.BROWSERSTACK_LOCAL || false,
|
|
12
|
+
opts: {
|
|
13
|
+
forcelocal: false,
|
|
14
|
+
// localIdentifier: "webdriverio-appium"
|
|
15
|
+
},
|
|
16
|
+
|
|
17
|
+
}]
|
|
18
|
+
],
|
|
19
|
+
// ====================
|
|
20
|
+
// Capabilities
|
|
21
|
+
// ====================
|
|
22
|
+
capabilities: [
|
|
23
|
+
{
|
|
24
|
+
'bstack:options': {
|
|
25
|
+
projectName: process.env.PROJECTNAME || "roboticodigital",
|
|
26
|
+
|
|
27
|
+
browserName: 'chrome', // Choose the browser you want to test
|
|
28
|
+
browserVersion: 'latest', // Specify the browser version
|
|
29
|
+
os: 'Windows', // Specify the operating system
|
|
30
|
+
os_version: '10', // Specify the operating system version
|
|
31
|
+
interactiveDebugging: true,
|
|
32
|
+
buildName: process.env.BROWSERSTACK_BUILD_NAME || 'WEB_Build',
|
|
33
|
+
networkLogs: "true",
|
|
34
|
+
debug: "true",
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
// Add more capabilities for other browsers or devices as needed
|
|
38
|
+
],
|
|
39
|
+
|
|
40
|
+
// ====================
|
|
41
|
+
// Test Configurations
|
|
42
|
+
// ====================
|
|
43
|
+
// logLevel: 'info', // Set the log level
|
|
44
|
+
// bail: 0, // Set to 1 to stop the test suite after the first test failure
|
|
45
|
+
// baseUrl: '', // Specify the base URL of your application
|
|
46
|
+
// waitforTimeout: 90000, // Set the timeout for all waitFor* commands
|
|
47
|
+
// connectionRetryTimeout: 90000, // Set the timeout in milliseconds for test retries
|
|
48
|
+
// connectionRetryCount: 2, // Set the number of times to retry the entire spec file
|
|
49
|
+
|
|
50
|
+
// ====================
|
|
51
|
+
// Framework
|
|
52
|
+
// ====================
|
|
53
|
+
// framework: 'mocha', // Use the Mocha framework
|
|
54
|
+
// reporters: ['spec'
|
|
55
|
+
|
|
56
|
+
// ], // Use the spec reporter
|
|
57
|
+
|
|
58
|
+
// ====================
|
|
59
|
+
// Hooks
|
|
60
|
+
// ====================
|
|
61
|
+
before: function (capabilities, specs) {
|
|
62
|
+
browser.maximizeWindow()
|
|
63
|
+
process.env.BS_SESSION_TYPE = "automate";
|
|
16
64
|
},
|
|
17
|
-
}],
|
|
18
|
-
runner: 'local',
|
|
19
65
|
|
|
20
|
-
before: function (capabilities, specs) {
|
|
21
|
-
// browser.maximizeWindow()
|
|
22
|
-
//process.env.BS_SESSION_TYPE = "app-automate";
|
|
23
|
-
},
|
|
24
66
|
|
|
25
67
|
|
|
68
|
+
// // ====================
|
|
69
|
+
// // Mocha Options
|
|
70
|
+
// // ====================
|
|
71
|
+
// mochaOpts: {
|
|
72
|
+
// ui: 'bdd', // Set the test interface to BDD
|
|
73
|
+
// timeout: 90000, // Set the timeout for test cases in milliseconds
|
|
74
|
+
// },
|
|
26
75
|
}]);
|
|
27
76
|
|
|
28
77
|
module.exports = apiconfig;
|