Skip to content

Commit 2bcd057

Browse files
committed
update env name + removed unused env
1 parent d13bf3c commit 2bcd057

File tree

5 files changed

+9
-12
lines changed

5 files changed

+9
-12
lines changed

bin/accessibility-automation/cypress/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,8 +342,7 @@ afterEach(() => {
342342
browserStackLog(`Cypress env browserstack testhub uuid: ${Cypress.env("BROWSERSTACK_TESTHUB_UUID")}`);
343343
browserStackLog(`Cypress env browserstack testhub jwt: ${Cypress.env("BROWSERSTACK_TESTHUB_JWT")}`);
344344
browserStackLog(`Cypress env http port: ${Cypress.env("BROWSERSTACK_TESTHUB_API_PORT")}`);
345-
browserStackLog(`test env: ${Cypress.env("TEST_ENV")}`);
346-
browserStackLog(`reporter api: ${Cypress.env("REPORTER_API")}`);
345+
browserStackLog(`reporter api: ${Cypress.env("REPORTER_API_PORT_NO")}`);
347346

348347
let testRunUuid = null;
349348
cy.task('get_test_run_uuid', { testIdentifier: attributes.title })

bin/accessibility-automation/plugin/index.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,13 @@ const browserstackAccessibility = (on, config) => {
1717
},
1818
get_test_run_uuid({ testIdentifier, retries = 15, interval = 300 } = {}) {
1919
return new Promise((resolve) => {
20-
console.log(`printing env variables take 6`);
20+
console.log(`printing env variables take 7`);
2121
console.log(`Cypress env browserstack testhub uuid from plugin: ${config.env.BROWSERSTACK_TESTHUB_UUID}`);
22-
console.log(`Cypress env http port: ${config.env.REPORTER_API}`);
23-
console.log(`test env: ${config.env.TEST_ENV}`);
24-
console.log(`reporter api from process: ${process.env.REPORTER_API}`);
22+
console.log(`Cypress env http port: ${config.env.REPORTER_API_PORT_NO}`);
23+
console.log(`reporter api from process: ${process.env.REPORTER_API_PORT_NO}`);
2524
console.log(`Fetching testRunUuid for testIdentifier: ${testIdentifier}`);
2625
if(!testIdentifier) return resolve(null);
27-
const port = process.env.REPORTER_API;
26+
const port = process.env.REPORTER_API_PORT_NO;
2827
let attempt = 0;
2928
const fetchUuid = () => {
3029
const options = {
@@ -105,7 +104,7 @@ const browserstackAccessibility = (on, config) => {
105104
config.env.BROWSERSTACK_TESTHUB_UUID = process.env.BROWSERSTACK_TESTHUB_UUID
106105
config.env.BROWSERSTACK_TESTHUB_JWT = process.env.BROWSERSTACK_TESTHUB_JWT
107106
config.env.BROWSERSTACK_TESTHUB_API_PORT = process.env.BROWSERSTACK_TESTHUB_API_PORT
108-
config.env.REPORTER_API = process.env.REPORTER_API
107+
config.env.REPORTER_API_PORT_NO = process.env.REPORTER_API_PORT_NO
109108

110109
config.env.IS_ACCESSIBILITY_EXTENSION_LOADED = browser_validation.toString()
111110

bin/commands/runs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ module.exports = function run(args, rawArgs) {
117117

118118
const preferredPort = 5348;
119119
const port = await findAvailablePort(preferredPort);
120-
process.env.REPORTER_API = port
120+
process.env.REPORTER_API_PORT_NO = port
121121

122122
// Send build start to TEST REPORTING AND ANALYTICS
123123
if(shouldProcessEventForTesthub()) {

bin/testObservability/reporter/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,8 +256,7 @@ class MyReporter {
256256
}
257257
});
258258

259-
const port = process.env.REPORTER_API;
260-
process.env.TEST_ENV = 'from-reporter';
259+
const port = process.env.REPORTER_API_PORT_NO;
261260

262261
this.httpServer.listen(port, '127.0.0.1', async () => {
263262
console.log(`Test Observability HTTP server listening on port ${port}`);

bin/testhub/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ exports.setTestHubCommonMetaInfo = (user_config, responseData) => {
234234
process.env.BROWSERSTACK_TESTHUB_UUID = responseData.build_hashed_id;
235235
user_config.run_settings.system_env_vars.push(`BROWSERSTACK_TESTHUB_JWT`);
236236
user_config.run_settings.system_env_vars.push(`BROWSERSTACK_TESTHUB_UUID`);
237-
user_config.run_settings.system_env_vars.push(`REPORTER_API`);
237+
user_config.run_settings.system_env_vars.push(`REPORTER_API_PORT_NO`);
238238
};
239239

240240
exports.checkIfAccessibilityIsSupported = (user_config, accessibilityFlag) => {

0 commit comments

Comments
 (0)