Skip to content

Commit d3ec912

Browse files
committed
changes
1 parent 0c978a6 commit d3ec912

File tree

4 files changed

+9
-3
lines changed

4 files changed

+9
-3
lines changed

src/constants.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,7 @@ declare module 'constants' {
1515

1616
export const TUNNEL_STOP_FAILED: string;
1717
export const TUNNEL_START_FAILED: string;
18+
export const appSessionURL: string;
19+
export const webSessionURL: string;
1820
}
1921

src/constants.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,7 @@ module.exports = {
55
baseUrlApp: "https://mobile-api.lambdatest.com/mobile-automation/api/",
66
TUNNEL_STOP_FAILED: "LambdaTest Tunnel failed to stop within 60 seconds!",
77
TUNNEL_START_FAILED :"LambdaTest Tunnel failed to start within 60 seconds!",
8-
TUNNEL_STOP_TIMEOUT:60000
8+
TUNNEL_STOP_TIMEOUT:60000,
9+
appSessionURL: "https://appautomation.lambdatest.com/test?testID",
10+
webSessionURL: "https://automation.lambdatest.com/test?testID"
911
};

src/service.d.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,4 +61,5 @@ export default class LambdaRestService implements Services.ServiceInstance {
6161
setSessionName(suiteTitle: string, test: Frameworks.Test): Promise<void>;
6262
_setSessionName(sessionName: string): Promise<void>;
6363
_executeCommand(cmd: string): Promise<void>;
64+
getSessionURL(sessionId: string, product: string): string;
6465
}

src/service.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import logger from '@wdio/logger'
22

33
import { getParentSuiteName, updateSessionById } from './util.js'
4+
import { appSessionURL, webSessionURL } from './constants.js';
45

56
const log = logger('@wdio/lambdatest-service')
67

@@ -415,8 +416,8 @@ export default class LambdaRestService {
415416

416417
getSessionURL(sessionId, product) {
417418
if (product === 'appAutomation') {
418-
return `https://appautomation.lambdatest.com/test?testID=${sessionId}`;
419+
return `${appSessionURL}=${sessionId}`;
419420
}
420-
return `https://automation.lambdatest.com/test?testID=${sessionId}`;
421+
return `${webSessionURL}=${sessionId}`;
421422
}
422423
}

0 commit comments

Comments
 (0)