froth-webdriverio-framework 3.0.67 → 3.0.69
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/api/browsersatckSessionInfo.js +2 -2
- package/config/commonconfig.js +10 -7
- package/config/wdio.common.conf.js +15 -14
- package/logs/bstack-wdio-service.log +74 -9
- package/logs/funnelData.json +1 -1
- package/package.json +1 -1
- package/web/testops_login.js +14 -0
- package/web_suites/websuites.js +5 -0
- package/ymls/browserstack/android/sample.yml +2 -2
- package/ymls/browserstack/web/web_sample.yml +13 -0
|
@@ -36,7 +36,7 @@ async function getBSBuildDetails(sessiontype, bs_username, bs_pwd) {
|
|
|
36
36
|
} else {
|
|
37
37
|
const errorText = await response.text();
|
|
38
38
|
console.error(`Data fetch failed response in getBSBuildDetails:${response.status}`);
|
|
39
|
-
|
|
39
|
+
// console.error(`Data fetch failed response in getBSBuildDetails:${errorText}`);
|
|
40
40
|
// throw new Error(`HTTP error! status: ${response.status}`);
|
|
41
41
|
}
|
|
42
42
|
|
|
@@ -81,7 +81,7 @@ async function getBSSessionDetails(sessiontype, bs_username, bs_pwd) {
|
|
|
81
81
|
const duration = data[0].automation_session.duration;
|
|
82
82
|
BUFFER.setItem("REPORT_URL", publicUrl)
|
|
83
83
|
BUFFER.setItem("FROTH_TOTAL_DURATION", duration)
|
|
84
|
-
|
|
84
|
+
console.log("public url:" + publicUrl)
|
|
85
85
|
//return jsondata;
|
|
86
86
|
} else if (response.status === 401) { //
|
|
87
87
|
console.log("Unauthorized, token expired")
|
package/config/commonconfig.js
CHANGED
|
@@ -23,7 +23,7 @@ const commonconfig = {
|
|
|
23
23
|
// await setAllDetails.setIntegrationsDetails();
|
|
24
24
|
await setAllDetails.setSuiteDetails();
|
|
25
25
|
await setAllDetails.setTestDataDetails();
|
|
26
|
-
|
|
26
|
+
console.log("on prepare:",JSON.stringify(capabilities))
|
|
27
27
|
// console.log("ALL JSON DATA in env variable :" + JSON.stringify(process.env));
|
|
28
28
|
} catch (e) {
|
|
29
29
|
console.log("====> Error in onPrepare:", e);
|
|
@@ -36,13 +36,16 @@ const commonconfig = {
|
|
|
36
36
|
console.log('====> This is the beforesession hook');
|
|
37
37
|
// Perform any setup or pre-test actions here
|
|
38
38
|
// console.log("Capabilities:", capabilities);
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
console.log("
|
|
42
|
-
console.log("
|
|
43
|
-
|
|
39
|
+
|
|
40
|
+
console.log("specdat:", specs);
|
|
41
|
+
console.log("length:", specs.length);
|
|
42
|
+
console.log("capabilities:", capabilities);
|
|
43
|
+
// capabilities.app = process.env.APP_PATH; // Replace with actual path
|
|
44
|
+
console.log("====>",capabilities)
|
|
44
45
|
console.log(`Running tests on: ${capabilities.platformName} ${capabilities.browserName} ${capabilities.browserVersion}`);
|
|
45
|
-
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
// console.log('specs:', specs);
|
|
46
49
|
// console.log("Config:", config);
|
|
47
50
|
},
|
|
48
51
|
/**
|
|
@@ -6,18 +6,21 @@ const commonconfig = require('./commonconfig');
|
|
|
6
6
|
|
|
7
7
|
// Select platform at runtime
|
|
8
8
|
const PLATFORM = process.env.PLATFORM || 'browserstack';
|
|
9
|
-
const configFile = PLATFORM === 'browserstack' ? '../ymls/
|
|
9
|
+
const configFile = PLATFORM === 'browserstack' ? __dirname + process.env.YML_NAME : '../ymls/saucelab/' + process.env.YML_NAME;
|
|
10
10
|
console.log('PLATFORM:', PLATFORM);
|
|
11
11
|
const SUITE_FILE = process.env.SUITE;
|
|
12
12
|
// Load YAML file
|
|
13
13
|
const capabilities = yaml.load(fs.readFileSync(path.join(__dirname, configFile), 'utf8'));
|
|
14
|
+
|
|
14
15
|
capabilities.buildName = process.env.BROWSERSTACK_BUILD_NAME;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
process.env.
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
if (PLATFORM === 'browserstack') {
|
|
19
|
+
process.env.BROWSERSTACK_USERNAME = capabilities.userName;
|
|
20
|
+
process.env.BROWSERSTACK_ACCESS_KEY = capabilities.accessKey;
|
|
21
|
+
process.env.BS_SESSION_TYPE = capabilities.platformName === 'android' || capabilities.platformName === 'ios' ? 'app-automate' : 'automate';
|
|
22
|
+
|
|
23
|
+
}
|
|
21
24
|
|
|
22
25
|
exports.config = deepmerge(commonconfig,
|
|
23
26
|
|
|
@@ -27,14 +30,14 @@ exports.config = deepmerge(commonconfig,
|
|
|
27
30
|
// debug: true,
|
|
28
31
|
// execArgv: ['--inspect-brk'],
|
|
29
32
|
services: PLATFORM === 'browserstack'
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
33
|
+
? ['browserstack']
|
|
34
|
+
: PLATFORM === 'saucelabs'
|
|
35
|
+
? ['sauce']
|
|
36
|
+
: [],
|
|
34
37
|
|
|
35
38
|
//runner: 'local',
|
|
36
39
|
specs: require(SUITE_FILE).tests,
|
|
37
|
-
|
|
40
|
+
|
|
38
41
|
maxInstances: 1,
|
|
39
42
|
capabilities: [capabilities],
|
|
40
43
|
|
|
@@ -47,8 +50,6 @@ exports.config = deepmerge(commonconfig,
|
|
|
47
50
|
connectionRetryTimeout: 90000,
|
|
48
51
|
connectionRetryCount: 3,
|
|
49
52
|
|
|
50
|
-
|
|
51
|
-
|
|
52
53
|
framework: 'mocha',
|
|
53
54
|
reporters: ['spec'],
|
|
54
55
|
maxInstances: 10,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
[90m2025-02-
|
|
1
|
+
[90m2025-02-19T05:55:09.449Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Sending SDK event with data {
|
|
2
2
|
userName: 'subhrasubudhi_uf8nhj',
|
|
3
3
|
accessKey: 'DUGGqze7p9QMZb84y66s',
|
|
4
4
|
event_type: 'SDKTestAttempted',
|
|
@@ -22,11 +22,76 @@
|
|
|
22
22
|
product: [ 'observability', 'automate' ]
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
|
-
[90m2025-02-
|
|
26
|
-
[90m2025-02-
|
|
27
|
-
[90m2025-02-
|
|
28
|
-
[90m2025-02-
|
|
29
|
-
[90m2025-02-
|
|
30
|
-
[90m2025-02-
|
|
31
|
-
[90m2025-02-
|
|
32
|
-
[90m2025-02-
|
|
25
|
+
[90m2025-02-19T05:55:09.777Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Funnel Event Response: "{\"message\":\"SDK Event recorded successfully\"}"
|
|
26
|
+
[90m2025-02-19T05:55:09.778Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Funnel event success
|
|
27
|
+
[90m2025-02-19T05:55:09.778Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m app is not defined in browserstack-service config, skipping ...
|
|
28
|
+
[90m2025-02-19T05:55:09.779Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Sending launch start event
|
|
29
|
+
[90m2025-02-19T05:55:11.108Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m [Start_Build] Success response: {"build_hashed_id":"91u9aev0hlljrxbwddcndynfpo91xvoblt7olgqq","jwt":"eyJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJicm93c2Vyc3RhY2tfb2IiLCJzdWIiOiI2MTA1MDM2IiwiZ3JvdXBfaWQiOjQ2OTIyNTksInVzZXJfaWQiOjYxMDUwMzYsImJ1aWxkX2hhc2hlZF9pZCI6IjkxdTlhZXYwaGxsanJ4YndkZGNuZHluZnBvOTF4dm9ibHQ3b2xncXEiLCJob29rX2FzX3Rlc3QiOiIxIiwiYnVpbGRfbmFtZSI6IldFQkRSSVZFUklPIiwicHJvZHVjdF9tYXAiOiJ7XCJvYnNlcnZhYmlsaXR5XCI6dHJ1ZSxcIm9yaWdpbkZyb21Qcm9kdWN0TWFwXCI6XCJVbmtub3duR3JpZFwiLFwiYnN0YWNrQXV0b21hdGlvblwiOmZhbHNlLFwicHJvZHVjdEZpbHRlclNvdXJjZVwiOmZhbHNlLFwiY2FkXCI6dHJ1ZX0iLCJncnJfcmVnaW9uIjoiIiwic2lnbmluZ19rZXlfaGFzaCI6IjdkZjZlNjgzYzY3MDkxYjZiY2FiNDk1ZTNmN2YyYWExNjljNzVmMzFmYmFmYTUwZjQ3MDI0YzgxYjllNzA1M2QiLCJpYXQiOjE3Mzk5NDQ1MTEsImV4cCI6MTc0MDI5MDExMX0.mv2fodtX2XFFBDi9DqkucO5qAUhheDp5wyP8Ful3Hmk","allow_screenshots":true}
|
|
30
|
+
[90m2025-02-19T05:55:11.108Z[39m [96mINFO[39m [97m@wdio/browserstack-service[39m browserstackLocal is not enabled - skipping...
|
|
31
|
+
[90m2025-02-19T05:55:21.571Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m teardown started
|
|
32
|
+
[90m2025-02-19T05:55:21.571Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m teardown ended
|
|
33
|
+
[90m2025-02-19T05:55:22.180Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Inside OnComplete hook..
|
|
34
|
+
[90m2025-02-19T05:55:22.180Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Sending stop launch event
|
|
35
|
+
[90m2025-02-19T05:55:23.169Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m [STOP_BUILD] Success response:
|
|
36
|
+
[90m2025-02-19T05:55:23.170Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Reading worker file worker-data-13538.json
|
|
37
|
+
[90m2025-02-19T05:55:23.175Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Sending SDK event with data {
|
|
38
|
+
userName: 'subhrasubudhi_uf8nhj',
|
|
39
|
+
accessKey: 'DUGGqze7p9QMZb84y66s',
|
|
40
|
+
event_type: 'SDKTestSuccessful',
|
|
41
|
+
detectedFramework: 'WebdriverIO-mocha',
|
|
42
|
+
event_properties: {
|
|
43
|
+
language_framework: 'WebdriverIO_mocha',
|
|
44
|
+
referrer: 'WebdriverIO-mocha/9.0.8',
|
|
45
|
+
language: 'WebdriverIO',
|
|
46
|
+
languageVersion: 'v20.15.0',
|
|
47
|
+
buildName: 'undefined',
|
|
48
|
+
buildIdentifier: 'undefined',
|
|
49
|
+
os: 'Darwin',
|
|
50
|
+
hostname: 'Subhras-MacBook-Pro.local',
|
|
51
|
+
productMap: {
|
|
52
|
+
observability: true,
|
|
53
|
+
accessibility: false,
|
|
54
|
+
percy: false,
|
|
55
|
+
automate: true,
|
|
56
|
+
app_automate: false
|
|
57
|
+
},
|
|
58
|
+
product: [ 'observability', 'automate' ],
|
|
59
|
+
productUsage: {
|
|
60
|
+
testObservability: {
|
|
61
|
+
enabled: true,
|
|
62
|
+
manuallySet: false,
|
|
63
|
+
buildHashedId: '91u9aev0hlljrxbwddcndynfpo91xvoblt7olgqq',
|
|
64
|
+
events: {
|
|
65
|
+
buildEvents: {
|
|
66
|
+
started: { isTriggered: true, status: 'success', error: undefined },
|
|
67
|
+
finished: { isTriggered: true, status: 'success', error: undefined }
|
|
68
|
+
},
|
|
69
|
+
testEvents: {
|
|
70
|
+
started: { triggeredCount: 0, sentCount: 0, failedCount: 0 },
|
|
71
|
+
finished: { triggeredCount: 0, sentCount: 0, failedCount: 0 }
|
|
72
|
+
},
|
|
73
|
+
hookEvents: {
|
|
74
|
+
started: { triggeredCount: 0, sentCount: 0, failedCount: 0 },
|
|
75
|
+
finished: { triggeredCount: 0, sentCount: 0, failedCount: 0 }
|
|
76
|
+
},
|
|
77
|
+
logEvents: { triggeredCount: 0, sentCount: 0, failedCount: 0 },
|
|
78
|
+
cbtSessionEvents: { triggeredCount: 0, sentCount: 0, failedCount: 0 }
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
[90m2025-02-19T05:55:24.307Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Funnel Event Response: "{\"message\":\"SDK Event recorded successfully\"}"
|
|
85
|
+
[90m2025-02-19T05:55:24.307Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Funnel event success
|
|
86
|
+
[90m2025-02-19T05:55:24.314Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Failed to fire api request due to TypeError: fetch failed - TypeError: fetch failed
|
|
87
|
+
at node:internal/deps/undici/undici:12502:13
|
|
88
|
+
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
|
|
89
|
+
at async nodeRequest (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/browserstack-service/build/index.js:880:22)
|
|
90
|
+
at async uploadLogs (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/browserstack-service/build/index.js:1808:20)
|
|
91
|
+
at async BrowserstackLauncherService._uploadServiceLogs (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/browserstack-service/build/index.js:3299:22)
|
|
92
|
+
at async BrowserstackLauncherService.onComplete (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/browserstack-service/build/index.js:3175:7)
|
|
93
|
+
at async file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/cli/build/index.js:1208:9
|
|
94
|
+
at async Promise.all (index 0)
|
|
95
|
+
at async Launcher.run (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/cli/build/index.js:2200:7)
|
|
96
|
+
at async Module.run (file:///Users/subhrasubudhi/WORKSPACES/WEBDRIVERIO/YTL_AF/WEBDRIVERIO/node_modules/@wdio/cli/build/index.js:3217:16)
|
|
97
|
+
[90m2025-02-19T05:55:24.314Z[39m [32mDEBUG[39m [97m@wdio/browserstack-service[39m Response - undefined
|
package/logs/funnelData.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"userName":"subhrasubudhi_uf8nhj","accessKey":"
|
|
1
|
+
{"userName":"subhrasubudhi_uf8nhj","accessKey":"DUGGqze7p9QMZb84y66s","event_type":"SDKTestSuccessful","detectedFramework":"WebdriverIO-mocha","event_properties":{"language_framework":"WebdriverIO_mocha","referrer":"WebdriverIO-mocha/9.0.8","language":"WebdriverIO","languageVersion":"v20.15.0","buildName":"undefined","buildIdentifier":"undefined","os":"Darwin","hostname":"Subhras-MacBook-Pro.local","productMap":{"observability":true,"accessibility":false,"percy":false,"automate":true,"app_automate":false},"product":["observability","automate"],"productUsage":{"testObservability":{"enabled":true,"manuallySet":false,"events":{"buildEvents":{"started":{},"finished":{}},"testEvents":{"started":{"triggeredCount":0,"sentCount":0,"failedCount":0},"finished":{"triggeredCount":0,"sentCount":0,"failedCount":0}},"hookEvents":{"started":{"triggeredCount":0,"sentCount":0,"failedCount":0},"finished":{"triggeredCount":0,"sentCount":0,"failedCount":0}},"logEvents":{"triggeredCount":0,"sentCount":0,"failedCount":0},"cbtSessionEvents":{"triggeredCount":0,"sentCount":0,"failedCount":0}}}}}}
|
package/package.json
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
const Util = require('../config/dataHandler.js');
|
|
2
|
+
|
|
3
|
+
describe("login testops", () => {
|
|
4
|
+
it("tests login testops", async () => {
|
|
5
|
+
await browser.url("https://uatrvrd.frothtestops.com/login")
|
|
6
|
+
await expect(browser).toHaveUrl("https://uatrvrd.frothtestops.com/login")
|
|
7
|
+
await browser.$("aria/Enter Email").click()
|
|
8
|
+
await browser.$("aria/Enter Email").setValue("admin@roboticodigital.com")
|
|
9
|
+
await browser.$("aria/Enter Password").click()
|
|
10
|
+
await browser.$("aria/Enter Password").setValue("Welcome@123")
|
|
11
|
+
await browser.$("aria/Login").click()
|
|
12
|
+
await browser.$("#vertical-menu-btn").click()
|
|
13
|
+
});
|
|
14
|
+
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
app: "
|
|
1
|
+
app: ""
|
|
2
2
|
userName: subhrasubudhi_uf8nhj
|
|
3
3
|
accessKey: DUGGqze7p9QMZb84y66s
|
|
4
4
|
platformName: android
|
|
@@ -13,5 +13,5 @@ deviceOrientation: "landscape"
|
|
|
13
13
|
networkLogs: true
|
|
14
14
|
debug: true
|
|
15
15
|
appProfiling: true
|
|
16
|
-
|
|
16
|
+
browserstack.uploadMedia: ["media://efd818ab0b4617a5af8d2d16dfdb29b03d28d4be","media://efd818ab0b4617a5af8d2d16dfdb29b03d28d4be"]
|
|
17
17
|
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
userName: naveen_OSt3Pw
|
|
2
|
+
accessKey: AuzPy8cHZ7sCBmMXakKe
|
|
3
|
+
platformName: MAC
|
|
4
|
+
browserName: Safari
|
|
5
|
+
os: OS X
|
|
6
|
+
osVersion: Monterey
|
|
7
|
+
browserVersion: 15.6
|
|
8
|
+
buildIdentifier: ${BUILD_NUMBER}
|
|
9
|
+
consoleLogs: info
|
|
10
|
+
browserstackLocal: true
|
|
11
|
+
debug: true
|
|
12
|
+
networkLogs: true
|
|
13
|
+
|