@lvce-editor/test-with-playwright-worker 2.1.0 → 2.3.0

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": "@lvce-editor/test-with-playwright-worker",
3
- "version": "2.1.0",
3
+ "version": "2.3.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -15,10 +15,10 @@
15
15
  "dependencies": {
16
16
  "@lvce-editor/assert": "^1.3.0",
17
17
  "@lvce-editor/command": "^1.2.0",
18
- "@lvce-editor/ipc": "^11.1.0",
19
- "@lvce-editor/json-rpc": "^5.0.0",
18
+ "@lvce-editor/ipc": "^11.6.0",
19
+ "@lvce-editor/json-rpc": "^5.2.0",
20
20
  "@lvce-editor/verror": "^1.6.0",
21
- "@playwright/test": "^1.48.2",
21
+ "@playwright/test": "^1.49.1",
22
22
  "get-port": "^7.1.0"
23
23
  },
24
24
  "devDependencies": {
@@ -0,0 +1,11 @@
1
+ import { join } from 'node:path'
2
+ import { pathToFileURL } from 'node:url'
3
+
4
+ export const getPossibleServerPaths = () => {
5
+ const toTry = [
6
+ '@lvce-editor/server',
7
+ pathToFileURL(join(process.cwd(), '..', 'server', 'node_modules', '@lvce-editor', 'server', 'index.js')).toString(),
8
+ pathToFileURL(join(process.cwd(), '..', 'build', 'node_modules', '@lvce-editor', 'server', 'index.js')).toString(),
9
+ ]
10
+ return toTry
11
+ }
@@ -1,12 +1,7 @@
1
- import { join } from 'node:path'
2
- import { pathToFileURL } from 'node:url'
1
+ import * as GetPossibleServerPaths from '../GetPossibleServerPaths/GetPossibleServerPaths.js'
3
2
 
4
3
  export const getServerPath = async () => {
5
- const toTry = [
6
- '@lvce-editor/server',
7
- pathToFileURL(join(process.cwd(), '..', 'server', 'node_modules', '@lvce-editor', 'server', 'index.js')).toString(),
8
- ]
9
-
4
+ const toTry = GetPossibleServerPaths.getPossibleServerPaths()
10
5
  for (const path of toTry) {
11
6
  try {
12
7
  const { serverPath } = await import(path)