@lambdatest/smartui-cli 4.1.42 → 4.1.44
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/dist/index.cjs +14 -14
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -2584,10 +2584,8 @@ var server_default = (ctx) => __async(void 0, null, function* () {
|
|
|
2584
2584
|
lastExternalResponse = externalResponse;
|
|
2585
2585
|
if (externalResponse.statusCode === 200) {
|
|
2586
2586
|
replyCode = 200;
|
|
2587
|
-
replyBody =
|
|
2588
|
-
|
|
2589
|
-
error: externalResponse.error.message
|
|
2590
|
-
};
|
|
2587
|
+
replyBody = externalResponse.data;
|
|
2588
|
+
replyBody.error = externalResponse.error.message;
|
|
2591
2589
|
return reply.code(replyCode).send(replyBody);
|
|
2592
2590
|
} else if (externalResponse.statusCode === 202) {
|
|
2593
2591
|
replyBody = externalResponse.data;
|
|
@@ -2605,10 +2603,8 @@ var server_default = (ctx) => __async(void 0, null, function* () {
|
|
|
2605
2603
|
ctx.log.debug(`Time passed: ${Date.now() - startTime}`);
|
|
2606
2604
|
if (Date.now() - startTime > timeoutDuration) {
|
|
2607
2605
|
replyCode = 202;
|
|
2608
|
-
replyBody =
|
|
2609
|
-
|
|
2610
|
-
data: lastExternalResponse.data
|
|
2611
|
-
};
|
|
2606
|
+
replyBody = lastExternalResponse.data;
|
|
2607
|
+
replyBody.error = "Request timed out, Snapshot still processing";
|
|
2612
2608
|
return reply.code(replyCode).send(replyBody);
|
|
2613
2609
|
}
|
|
2614
2610
|
} catch (externalApiError) {
|
|
@@ -2676,7 +2672,8 @@ var env_default = () => {
|
|
|
2676
2672
|
SHOW_RENDER_ERRORS,
|
|
2677
2673
|
SMARTUI_SSE_URL = "https://server-events.lambdatest.com",
|
|
2678
2674
|
LT_SDK_SKIP_EXECUTION_LOGS,
|
|
2679
|
-
MAX_CONCURRENT_PROCESSING
|
|
2675
|
+
MAX_CONCURRENT_PROCESSING,
|
|
2676
|
+
DO_NOT_USE_USER_AGENT
|
|
2680
2677
|
} = process.env;
|
|
2681
2678
|
return {
|
|
2682
2679
|
PROJECT_TOKEN,
|
|
@@ -2703,7 +2700,8 @@ var env_default = () => {
|
|
|
2703
2700
|
SHOW_RENDER_ERRORS: SHOW_RENDER_ERRORS === "true",
|
|
2704
2701
|
SMARTUI_SSE_URL,
|
|
2705
2702
|
LT_SDK_SKIP_EXECUTION_LOGS: LT_SDK_SKIP_EXECUTION_LOGS === "true",
|
|
2706
|
-
MAX_CONCURRENT_PROCESSING: MAX_CONCURRENT_PROCESSING ? parseInt(MAX_CONCURRENT_PROCESSING, 10) : 0
|
|
2703
|
+
MAX_CONCURRENT_PROCESSING: MAX_CONCURRENT_PROCESSING ? parseInt(MAX_CONCURRENT_PROCESSING, 10) : 0,
|
|
2704
|
+
DO_NOT_USE_USER_AGENT: DO_NOT_USE_USER_AGENT === "true"
|
|
2707
2705
|
};
|
|
2708
2706
|
};
|
|
2709
2707
|
var logContext = {};
|
|
@@ -2798,7 +2796,7 @@ var authExec_default = (ctx) => {
|
|
|
2798
2796
|
};
|
|
2799
2797
|
|
|
2800
2798
|
// package.json
|
|
2801
|
-
var version = "4.1.
|
|
2799
|
+
var version = "4.1.44";
|
|
2802
2800
|
var package_default = {
|
|
2803
2801
|
name: "@lambdatest/smartui-cli",
|
|
2804
2802
|
version,
|
|
@@ -4426,9 +4424,11 @@ function processSnapshot(snapshot, ctx) {
|
|
|
4426
4424
|
};
|
|
4427
4425
|
let contextOptions = {
|
|
4428
4426
|
javaScriptEnabled: ctx.config.cliEnableJavaScript,
|
|
4429
|
-
userAgent: constants_default.CHROME_USER_AGENT,
|
|
4430
4427
|
ignoreHTTPSErrors: ctx.config.ignoreHTTPSErrors
|
|
4431
4428
|
};
|
|
4429
|
+
if (!ctx.env.DO_NOT_USE_USER_AGENT) {
|
|
4430
|
+
contextOptions.userAgent = constants_default.CHROME_USER_AGENT;
|
|
4431
|
+
}
|
|
4432
4432
|
if (!((_b = ctx.browser) == null ? void 0 : _b.isConnected())) {
|
|
4433
4433
|
if (ctx.env.HTTP_PROXY || ctx.env.HTTPS_PROXY)
|
|
4434
4434
|
launchOptions.proxy = { server: ctx.env.HTTP_PROXY || ctx.env.HTTPS_PROXY };
|
|
@@ -5573,7 +5573,7 @@ var startTunnel_default = (ctx) => {
|
|
|
5573
5573
|
|
|
5574
5574
|
// src/commander/exec.ts
|
|
5575
5575
|
var command = new commander.Command();
|
|
5576
|
-
command.name("exec").description("Run test commands around SmartUI").argument("<command...>", "Command supplied for running tests").option("-P, --port <number>", "Port number for the server").option("--fetch-results [filename]", "Fetch results and optionally specify an output file, e.g., <filename>.json").option("--buildName <string>", "Specify the build name").option("--scheduled <string>", "Specify the schedule ID").option("--
|
|
5576
|
+
command.name("exec").description("Run test commands around SmartUI").argument("<command...>", "Command supplied for running tests").option("-P, --port <number>", "Port number for the server").option("--fetch-results [filename]", "Fetch results and optionally specify an output file, e.g., <filename>.json").option("--buildName <string>", "Specify the build name").option("--scheduled <string>", "Specify the schedule ID").option("--show-render-errors", "Show render errors from SmartUI build").action(function(execCommand, _, command11) {
|
|
5577
5577
|
return __async(this, null, function* () {
|
|
5578
5578
|
var _a;
|
|
5579
5579
|
const options = command11.optsWithGlobals();
|
|
@@ -7332,7 +7332,7 @@ var uploadPdf_default = command10;
|
|
|
7332
7332
|
|
|
7333
7333
|
// src/commander/commander.ts
|
|
7334
7334
|
var program2 = new commander.Command();
|
|
7335
|
-
program2.name("smartui").description("CLI to help you run your SmartUI tests on LambdaTest platform").version(`v${version}`).option("-c --config <filepath>", "Config file path").option("--markBaseline", "Mark this build baseline").option("--baselineBranch <string>", "Mark this build baseline").option("--baselineBuild <string>", "Mark this build baseline").option("--githubURL <string>", "GitHub URL including commitId").addCommand(exec_default2).addCommand(capture_default).addCommand(configWeb).addCommand(configStatic).addCommand(upload_default).addCommand(server_default2).addCommand(stopServer_default).addCommand(merge_default).addCommand(ping_default).addCommand(configFigma).addCommand(uploadFigma).addCommand(configWebFigma).addCommand(configAppFigma).addCommand(uploadWebFigmaCommand).addCommand(uploadAppFigmaCommand).addCommand(pingTest_default).addCommand(uploadPdf_default);
|
|
7335
|
+
program2.name("smartui").description("CLI to help you run your SmartUI tests on LambdaTest platform").version(`v${version}`).option("-c --config <filepath>", "Config file path").option("--markBaseline", "Mark this build baseline").option("--baselineBranch <string>", "Mark this build baseline").option("--baselineBuild <string>", "Mark this build baseline").option("--githubURL <string>", "GitHub URL including commitId").option("--userName <string>", "Specify the LT username").option("--accessKey <string>", "Specify the LT accesskey").addCommand(exec_default2).addCommand(capture_default).addCommand(configWeb).addCommand(configStatic).addCommand(upload_default).addCommand(server_default2).addCommand(stopServer_default).addCommand(merge_default).addCommand(ping_default).addCommand(configFigma).addCommand(uploadFigma).addCommand(configWebFigma).addCommand(configAppFigma).addCommand(uploadWebFigmaCommand).addCommand(uploadAppFigmaCommand).addCommand(pingTest_default).addCommand(uploadPdf_default);
|
|
7336
7336
|
var commander_default = program2;
|
|
7337
7337
|
(function() {
|
|
7338
7338
|
return __async(this, null, function* () {
|