@browsermation/test 0.0.29 → 0.0.30

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 CHANGED
@@ -42258,7 +42258,7 @@ var {
42258
42258
  // package.json
42259
42259
  var package_default = {
42260
42260
  name: "@browsermation/test",
42261
- version: "0.0.29",
42261
+ version: "0.0.30",
42262
42262
  description: "The testing platform for Playwright by Browsermation.",
42263
42263
  main: "./dist/index.js",
42264
42264
  types: "./dist/index.d.ts",
package/dist/index.js CHANGED
@@ -589,18 +589,20 @@ function startTunnel(tunnelProcess2, options) {
589
589
 
590
590
  // src/defineConfig.ts
591
591
  async function fetchEndpoint() {
592
- if (!process.env.SERVER_URL) {
593
- console.error(
594
- source_default.red.bold("\u274C Error: SERVER_URL environment variable is not set")
595
- );
596
- process.exit(1);
592
+ if (!process.env.BM_SERVER_URL) {
593
+ process.env.BM_SERVER_URL = "https://browsermation.test/api/v1/tasks/tests/playwright/ws";
597
594
  }
598
595
  let protocol = import_node_https.default;
599
- if (process.env.SERVER_URL.startsWith("http:")) {
596
+ if (process.env.BM_SERVER_URL.startsWith("http:")) {
600
597
  protocol = import_node_http.default;
601
598
  }
602
599
  return new Promise((resolve, reject) => {
603
- protocol.get(process.env.SERVER_URL || "", (res) => {
600
+ const options = {
601
+ headers: {
602
+ Authorization: process.env.BM_API_TOKEN || ""
603
+ }
604
+ };
605
+ protocol.get(process.env.BM_SERVER_URL || "", options, (res) => {
604
606
  if (res.statusCode && (res.statusCode < 200 || res.statusCode >= 300)) {
605
607
  return reject(new Error(`HTTP status code ${res.statusCode} received`));
606
608
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@browsermation/test",
3
- "version": "0.0.29",
3
+ "version": "0.0.30",
4
4
  "description": "The testing platform for Playwright by Browsermation.",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",