@auxcode/auxta 0.3.4 → 0.3.5

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@auxcode/auxta",
3
- "version": "0.3.4",
3
+ "version": "0.3.5",
4
4
  "description": "",
5
5
  "main": "src/AuxTA.ts",
6
6
  "scripts": {
package/src/AuxTA.ts CHANGED
@@ -62,14 +62,14 @@ class AuxTA extends FunctionHelper {
62
62
  if (overrideConfig) {
63
63
  if (overrideConfig.digitalProduct) this.uploadModel.digitalProduct = overrideConfig.digitalProduct
64
64
  if (overrideConfig.environment) this.uploadModel.environment = overrideConfig.environment
65
- if (overrideConfig.baseUrl) this.uploadModel.baseUrl = overrideConfig.baseUrl
65
+ if (overrideConfig.baseURL) this.uploadModel.baseUrl = overrideConfig.baseURL
66
66
  this.config = setupOverrideConfig(overrideConfig)
67
67
  }
68
68
  }
69
69
 
70
70
  public async startBrowser(event: any, callback: any, feature: string, scenario: string, overrideConfig?: any, singleFeature = false) {
71
71
  this.changeModelData(overrideConfig);
72
- if (singleFeature) {
72
+ if (singleFeature && process.env.ENVIRONMENT !== 'LOCAL') {
73
73
  if (process.env.ENVIRONMENT === 'LIVE' && event.queryStringParameters.token !== this.config.token)
74
74
  return {statusCode: 401, message: 'Unauthorized'}
75
75
  this.uploadModel.reportId = await createEmptyReport(this.uploadModel);
@@ -24,6 +24,8 @@ export function setupConfig(jsonConfig: any) {
24
24
  export function setupOverrideConfig(overrideConfig: any){
25
25
  if (overrideConfig.baseURL) config.baseURL = overrideConfig.baseURL;
26
26
  if (overrideConfig.digitalProduct) config.digitalProduct = overrideConfig.digitalProduct;
27
+ if (overrideConfig.screenWidth) config.screenWidth = overrideConfig.screenWidth;
28
+ if (overrideConfig.screenHeight) config.screenHeight = overrideConfig.screenHeight;
27
29
  return config;
28
30
  }
29
31
 
@@ -112,7 +112,7 @@ export class FunctionHelper {
112
112
  log.push('And', message, StatusOfStep.PASSED);
113
113
  }
114
114
 
115
- public async click(selector: string, page = puppeteer.defaultPage) {
115
+ public async click(selector: string, logMessages = true, page = puppeteer.defaultPage) {
116
116
  try{
117
117
  await page.waitForSelector(selector, {
118
118
  timeout: this.defaultTimeout