@browsermation/test 0.0.51 → 0.0.52
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/bin/cli.js +13 -3
- package/dist/index.js +9 -1
- package/package.json +1 -1
package/dist/bin/cli.js
CHANGED
|
@@ -42258,7 +42258,7 @@ var {
|
|
|
42258
42258
|
// package.json
|
|
42259
42259
|
var package_default = {
|
|
42260
42260
|
name: "@browsermation/test",
|
|
42261
|
-
version: "0.0.
|
|
42261
|
+
version: "0.0.52",
|
|
42262
42262
|
description: "The testing platform for Playwright by Browsermation.",
|
|
42263
42263
|
main: "./dist/index.js",
|
|
42264
42264
|
types: "./dist/index.d.ts",
|
|
@@ -46661,6 +46661,14 @@ function startTunnel(tunnelProcess, options) {
|
|
|
46661
46661
|
);
|
|
46662
46662
|
process.exit(1);
|
|
46663
46663
|
}
|
|
46664
|
+
if (!options?.port) {
|
|
46665
|
+
console.error(
|
|
46666
|
+
source_default.red.bold(
|
|
46667
|
+
"\u274C Error: Please provide a port to expose via the tunnel using the --tunnel or --port option."
|
|
46668
|
+
)
|
|
46669
|
+
);
|
|
46670
|
+
process.exit(1);
|
|
46671
|
+
}
|
|
46664
46672
|
const tunnelDomain = `${options.subdomain || crypto.randomUUID()}.browsermationtunnel.com`;
|
|
46665
46673
|
tunnelProcess = (0, import_node_child_process.spawn)("ssh", [
|
|
46666
46674
|
"-o",
|
|
@@ -46668,7 +46676,7 @@ function startTunnel(tunnelProcess, options) {
|
|
|
46668
46676
|
"-o",
|
|
46669
46677
|
"UserKnownHostsFile=/dev/null",
|
|
46670
46678
|
"-R",
|
|
46671
|
-
`:80:localhost:${options.
|
|
46679
|
+
`:80:localhost:${options.port}`,
|
|
46672
46680
|
"v0@browsermationtunnel.com",
|
|
46673
46681
|
"-p",
|
|
46674
46682
|
"2200",
|
|
@@ -46759,7 +46767,9 @@ program2.command("test").option("-t, --tunnel <port>").option("-p, --proxy").opt
|
|
|
46759
46767
|
proxy: false
|
|
46760
46768
|
};
|
|
46761
46769
|
if (options.tunnel) {
|
|
46762
|
-
const startTunnelResult = await startTunnel(tunnelProcess,
|
|
46770
|
+
const startTunnelResult = await startTunnel(tunnelProcess, {
|
|
46771
|
+
port: options.tunnel
|
|
46772
|
+
});
|
|
46763
46773
|
tunnelProcess = startTunnelResult.tunnelProcess;
|
|
46764
46774
|
}
|
|
46765
46775
|
if (options.proxy) {
|
package/dist/index.js
CHANGED
|
@@ -545,6 +545,14 @@ function startTunnel(tunnelProcess2, options) {
|
|
|
545
545
|
);
|
|
546
546
|
process.exit(1);
|
|
547
547
|
}
|
|
548
|
+
if (!options?.port) {
|
|
549
|
+
console.error(
|
|
550
|
+
source_default.red.bold(
|
|
551
|
+
"\u274C Error: Please provide a port to expose via the tunnel using the --tunnel or --port option."
|
|
552
|
+
)
|
|
553
|
+
);
|
|
554
|
+
process.exit(1);
|
|
555
|
+
}
|
|
548
556
|
const tunnelDomain = `${options.subdomain || crypto.randomUUID()}.browsermationtunnel.com`;
|
|
549
557
|
tunnelProcess2 = (0, import_node_child_process.spawn)("ssh", [
|
|
550
558
|
"-o",
|
|
@@ -552,7 +560,7 @@ function startTunnel(tunnelProcess2, options) {
|
|
|
552
560
|
"-o",
|
|
553
561
|
"UserKnownHostsFile=/dev/null",
|
|
554
562
|
"-R",
|
|
555
|
-
`:80:localhost:${options.
|
|
563
|
+
`:80:localhost:${options.port}`,
|
|
556
564
|
"v0@browsermationtunnel.com",
|
|
557
565
|
"-p",
|
|
558
566
|
"2200",
|