@lvce-editor/test-worker 4.27.0 → 4.29.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/dist/api.d.ts CHANGED
@@ -91,6 +91,7 @@ declare const handleInputBlur: () => Promise<void>;
91
91
  declare const focus$1: () => Promise<void>;
92
92
  declare const focusNext$2: () => Promise<void>;
93
93
  declare const selectUp: () => Promise<void>;
94
+ declare const handleDragOverIndex: (index: number) => Promise<void>;
94
95
  declare const selectDown: () => Promise<void>;
95
96
  declare const refresh: () => Promise<void>;
96
97
  declare const focusIndex: (index: number) => Promise<void>;
@@ -114,13 +115,19 @@ declare const updateEditingValue: (value: string) => Promise<void>;
114
115
  declare const expandAll: () => Promise<void>;
115
116
  declare const handleDragOver: (x: number, y: number) => Promise<void>;
116
117
  declare const handleCut: () => Promise<void>;
118
+ declare const handleCopy: () => Promise<void>;
117
119
  declare const handlePaste: () => Promise<void>;
118
120
  declare const selectIndices: (indices: readonly number[]) => Promise<void>;
121
+ declare const toggleIndividualSelection: (index: number) => Promise<void>;
119
122
  declare const addWebExtension: (relativePath: string) => Promise<void>;
120
123
  declare const addNodeExtension: (relativePath: string) => Promise<void>;
121
124
  declare const selectFeature: (name: string) => Promise<void>;
122
125
  declare const selectTab: (name: string) => Promise<void>;
123
126
  declare const open: (extensionId: string) => Promise<void>;
127
+ declare const openFeature: (featureName: string) => Promise<void>;
128
+ declare const openThemes: () => Promise<void>;
129
+ declare const openCommands: () => Promise<void>;
130
+ declare const openWebViews: () => Promise<void>;
124
131
  declare const writeFile: (path: string, content: string) => Promise<void>;
125
132
  declare const mkdir: (path: string) => Promise<void>;
126
133
  declare const remove: (uri: string) => Promise<void>;
@@ -177,14 +184,23 @@ declare const open$2: (id: string) => Promise<void>;
177
184
  declare const getNodePath: () => Promise<string>;
178
185
  declare const isFirefox: () => boolean;
179
186
  declare const show$1: () => Promise<void>;
187
+ declare const handleFilterInput: (text: string) => Promise<void>;
188
+ declare const copyMessage: () => Promise<void>;
189
+ declare const focusIndex$1: (index: number) => Promise<void>;
190
+ declare const handleArrowLeft$1: () => Promise<void>;
191
+ declare const handleArrowRight: () => Promise<void>;
192
+ declare const handleClickAt$1: (x: number, y: number) => Promise<void>;
193
+ declare const handleIconThemeChange: () => Promise<void>;
194
+ declare const viewAsList: () => Promise<void>;
195
+ declare const viewAsTable: () => Promise<void>;
180
196
  declare const open$3: () => Promise<void>;
181
197
  declare const handleInput$1: (value: string) => Promise<void>;
182
- declare const handleClickAt$1: (x: number, y: number) => Promise<void>;
198
+ declare const handleClickAt$2: (x: number, y: number) => Promise<void>;
183
199
  declare const setValue$1: (value: string) => Promise<void>;
184
200
  declare const focusNext$7: () => Promise<void>;
185
201
  declare const focusFirst$5: () => Promise<void>;
186
202
  declare const focusLast$5: () => Promise<void>;
187
- declare const focusIndex$1: (index: number) => Promise<void>;
203
+ declare const focusIndex$2: (index: number) => Promise<void>;
188
204
  declare const focusPrevious$5: () => Promise<void>;
189
205
  declare const selectItem$1: (label: string) => Promise<void>;
190
206
  declare const selectIndex$2: (index: number) => Promise<void>;
@@ -208,7 +224,7 @@ declare const openDetails: () => Promise<void>;
208
224
  declare const collapseDetails: () => Promise<void>;
209
225
  declare const dismissItem: () => Promise<void>;
210
226
  declare const focusFirst$6: () => Promise<void>;
211
- declare const focusIndex$2: (index: number) => Promise<void>;
227
+ declare const focusIndex$3: (index: number) => Promise<void>;
212
228
  declare const selectIndex$4: (index: number) => Promise<void>;
213
229
  declare const focusNext$8: () => Promise<void>;
214
230
  declare const handleWheel$1: (deltaMode: number, deltaY: number) => Promise<void>;
@@ -232,7 +248,7 @@ declare const update$1: () => Promise<void>;
232
248
  declare const closeMenu: () => Promise<void>;
233
249
  declare const focus$2: () => Promise<void>;
234
250
  declare const focusFirst$7: () => Promise<void>;
235
- declare const focusIndex$3: (index: number) => Promise<void>;
251
+ declare const focusIndex$4: (index: number) => Promise<void>;
236
252
  declare const focusLast$6: () => Promise<void>;
237
253
  declare const focusNext$9: () => Promise<void>;
238
254
  declare const focusPrevious$7: () => Promise<void>;
@@ -246,11 +262,14 @@ declare const handleKeySpace: () => Promise<void>;
246
262
  declare const handleKeyEscape: () => Promise<void>;
247
263
  declare const toggleIndex: (index: number) => Promise<void>;
248
264
  declare const toggleMenu: () => Promise<void>;
265
+ declare const setUrl: (newUrl: string) => void;
266
+ declare const resolve: (relativePath: string) => string;
249
267
  declare const fromId: (webViewId: string) => Promise<any>;
250
268
  declare const setPath: (path: string) => Promise<void>;
269
+ declare const openTmpDir: () => Promise<string>;
251
270
 
252
271
  declare namespace Workspace {
253
- export { setPath };
272
+ export { openTmpDir, setPath };
254
273
  }
255
274
  declare namespace About {
256
275
  export { focusNext, focusPrevious, handleClickClose, handleClickCopy, handleClickOk, show };
@@ -280,13 +299,13 @@ declare namespace EditorCompletion {
280
299
  export { selectCurrentIndex, selectIndex };
281
300
  }
282
301
  declare namespace Explorer {
283
- export { acceptEdit, cancelEdit, clickCurrent, expandAll, expandRecursively, focus$1 as focus, focusFirst$1 as focusFirst, focusIndex, focusLast$1 as focusLast, focusNext$2 as focusNext, handleArrowLeft, handleBlur, handleClick$1 as handleClick, handleClickAt, handleCut, handleDragLeave, handleDragOver, handleDrop, handleInputBlur, handlePaste, newFile, newFolder, openContextMenu$1 as openContextMenu, refresh, removeDirent, rename$1 as rename, renameDirent, selectAll$1 as selectAll, selectDown, selectIndices, selectUp, updateEditingValue };
302
+ export { acceptEdit, cancelEdit, clickCurrent, expandAll, expandRecursively, focus$1 as focus, focusFirst$1 as focusFirst, focusIndex, focusLast$1 as focusLast, focusNext$2 as focusNext, handleArrowLeft, handleBlur, handleClick$1 as handleClick, handleClickAt, handleCopy, handleCut, handleDragLeave, handleDragOver, handleDragOverIndex, handleDrop, handleInputBlur, handlePaste, newFile, newFolder, openContextMenu$1 as openContextMenu, refresh, removeDirent, rename$1 as rename, renameDirent, selectAll$1 as selectAll, selectDown, selectIndices, selectUp, toggleIndividualSelection, updateEditingValue };
284
303
  }
285
304
  declare namespace Extension {
286
305
  export { addNodeExtension, addWebExtension };
287
306
  }
288
307
  declare namespace ExtensionDetail {
289
- export { open, selectFeature, selectTab };
308
+ export { open, openCommands, openFeature, openThemes, openWebViews, selectFeature, selectTab };
290
309
  }
291
310
  declare namespace FileSystem {
292
311
  export { chmod, createExecutable, createExecutableFrom, getTmpDir, mkdir, remove, writeFile };
@@ -316,16 +335,16 @@ declare namespace Platform {
316
335
  export { getNodePath, isFirefox };
317
336
  }
318
337
  declare namespace Problems {
319
- export { show$1 as show };
338
+ export { copyMessage, focusIndex$1 as focusIndex, handleArrowLeft$1 as handleArrowLeft, handleArrowRight, handleClickAt$1 as handleClickAt, handleFilterInput, handleIconThemeChange, show$1 as show, viewAsList, viewAsTable };
320
339
  }
321
340
  declare namespace QuickPick {
322
- export { executeCommand, focusFirst$5 as focusFirst, focusIndex$1 as focusIndex, focusLast$5 as focusLast, focusNext$7 as focusNext, focusPrevious$5 as focusPrevious, handleClickAt$1 as handleClickAt, handleInput$1 as handleInput, open$3 as open, selectCurrentIndex$1 as selectCurrentIndex, selectIndex$2 as selectIndex, selectItem$1 as selectItem, setValue$1 as setValue };
341
+ export { executeCommand, focusFirst$5 as focusFirst, focusIndex$2 as focusIndex, focusLast$5 as focusLast, focusNext$7 as focusNext, focusPrevious$5 as focusPrevious, handleClickAt$2 as handleClickAt, handleInput$1 as handleInput, open$3 as open, selectCurrentIndex$1 as selectCurrentIndex, selectIndex$2 as selectIndex, selectItem$1 as selectItem, setValue$1 as setValue };
323
342
  }
324
343
  declare namespace RunAndDebug {
325
344
  export { acceptWatchExpressionEdit, addWatchExpression, handleClickSectionWatch, handleRename, handleSpace, handleWatchValueChange, selectIndex$3 as selectIndex, setPauseOnExceptions };
326
345
  }
327
346
  declare namespace Search {
328
- export { clearSearchResults, collapseDetails, dismissItem, focusFirst$6 as focusFirst, focusIndex$2 as focusIndex, focusNext$8 as focusNext, focusNextPage, focusPrevious$6 as focusPrevious, focusPreviousPage, handleWheel$1 as handleWheel, openDetails, replaceAll, selectIndex$4 as selectIndex, setExcludeValue, setIncludeValue, setReplaceValue, setValue$2 as setValue, toggleMatchCase, toggleMatchWholeWord, togglePreserveCase, toggleReplace, toggleSearchDetails, toggleUseRegularExpression };
347
+ export { clearSearchResults, collapseDetails, dismissItem, focusFirst$6 as focusFirst, focusIndex$3 as focusIndex, focusNext$8 as focusNext, focusNextPage, focusPrevious$6 as focusPrevious, focusPreviousPage, handleWheel$1 as handleWheel, openDetails, replaceAll, selectIndex$4 as selectIndex, setExcludeValue, setIncludeValue, setReplaceValue, setValue$2 as setValue, toggleMatchCase, toggleMatchWholeWord, togglePreserveCase, toggleReplace, toggleSearchDetails, toggleUseRegularExpression };
329
348
  }
330
349
  declare namespace Settings {
331
350
  export { update };
@@ -340,7 +359,10 @@ declare namespace StatusBar {
340
359
  export { update$1 as update };
341
360
  }
342
361
  declare namespace TitleBarMenuBar {
343
- export { closeMenu, focus$2 as focus, focusFirst$7 as focusFirst, focusIndex$3 as focusIndex, focusLast$6 as focusLast, focusNext$9 as focusNext, focusPrevious$7 as focusPrevious, handleKeyArrowDown, handleKeyArrowLeft, handleKeyArrowRight, handleKeyArrowUp, handleKeyEnd, handleKeyEscape, handleKeyHome, handleKeySpace, toggleIndex, toggleMenu };
362
+ export { closeMenu, focus$2 as focus, focusFirst$7 as focusFirst, focusIndex$4 as focusIndex, focusLast$6 as focusLast, focusNext$9 as focusNext, focusPrevious$7 as focusPrevious, handleKeyArrowDown, handleKeyArrowLeft, handleKeyArrowRight, handleKeyArrowUp, handleKeyEnd, handleKeyEscape, handleKeyHome, handleKeySpace, toggleIndex, toggleMenu };
363
+ }
364
+ declare namespace Url {
365
+ export { resolve, setUrl };
344
366
  }
345
367
  declare namespace WebView {
346
368
  export { fromId };
@@ -377,6 +399,7 @@ export interface TestApi {
377
399
  readonly SourceControl: typeof SourceControl,
378
400
  readonly StatusBar: typeof StatusBar,
379
401
  readonly TitleBarMenuBar: typeof TitleBarMenuBar,
402
+ readonly Url: typeof Url,
380
403
  readonly WebView: typeof WebView,
381
404
  readonly Workspace: typeof Workspace,
382
405
  readonly expect: any
@@ -60,37 +60,45 @@ let AssertionError$1 = class AssertionError extends Error {
60
60
  this.name = 'AssertionError';
61
61
  }
62
62
  };
63
+ const Object$1 = 1;
64
+ const Number$1 = 2;
65
+ const Array$1 = 3;
66
+ const String = 4;
67
+ const Boolean = 5;
68
+ const Function = 6;
69
+ const Null = 7;
70
+ const Unknown = 8;
63
71
  const getType = value => {
64
72
  switch (typeof value) {
65
73
  case 'number':
66
- return 'number';
74
+ return Number$1;
67
75
  case 'function':
68
- return 'function';
76
+ return Function;
69
77
  case 'string':
70
- return 'string';
78
+ return String;
71
79
  case 'object':
72
80
  if (value === null) {
73
- return 'null';
81
+ return Null;
74
82
  }
75
83
  if (Array.isArray(value)) {
76
- return 'array';
84
+ return Array$1;
77
85
  }
78
- return 'object';
86
+ return Object$1;
79
87
  case 'boolean':
80
- return 'boolean';
88
+ return Boolean;
81
89
  default:
82
- return 'unknown';
90
+ return Unknown;
83
91
  }
84
92
  };
85
93
  const object = value => {
86
94
  const type = getType(value);
87
- if (type !== 'object') {
95
+ if (type !== Object$1) {
88
96
  throw new AssertionError$1('expected value to be of type object');
89
97
  }
90
98
  };
91
99
  const string$1 = value => {
92
100
  const type = getType(value);
93
- if (type !== 'string') {
101
+ if (type !== String) {
94
102
  throw new AssertionError$1('expected value to be of type string');
95
103
  }
96
104
  };
@@ -695,7 +703,7 @@ const unwrapJsonRpcResult = responseMessage => {
695
703
  const warn = (...args) => {
696
704
  console.warn(...args);
697
705
  };
698
- const resolve = (id, response) => {
706
+ const resolve$1 = (id, response) => {
699
707
  const fn = get$2(id);
700
708
  if (!fn) {
701
709
  console.log(response);
@@ -802,7 +810,7 @@ const defaultLogError = () => {
802
810
  const defaultRequiresSocket = () => {
803
811
  return false;
804
812
  };
805
- const defaultResolve = resolve;
813
+ const defaultResolve = resolve$1;
806
814
 
807
815
  // TODO maybe remove this in v6 or v7, only accept options object to simplify the code
808
816
  const normalizeParams = args => {
@@ -932,7 +940,7 @@ const logError = () => {
932
940
  const handleMessage = event => {
933
941
  const actualRequiresSocket = event?.target?.requiresSocket || requiresSocket;
934
942
  const actualExecute = event?.target?.execute || execute$2;
935
- return handleJsonRpcMessage(event.target, event.data, actualExecute, resolve, preparePrettyError, logError, actualRequiresSocket);
943
+ return handleJsonRpcMessage(event.target, event.data, actualExecute, resolve$1, preparePrettyError, logError, actualRequiresSocket);
936
944
  };
937
945
  const handleIpc = ipc => {
938
946
  if ('addEventListener' in ipc) {
@@ -950,7 +958,7 @@ const listen$1 = async (module, options) => {
950
958
  const ipc = module.wrap(rawIpc);
951
959
  return ipc;
952
960
  };
953
- const create$9 = async ({
961
+ const create$d = async ({
954
962
  commandMap,
955
963
  messagePort,
956
964
  isMessagePortOpen
@@ -968,7 +976,7 @@ const create$9 = async ({
968
976
  };
969
977
  const MessagePortRpcParent = {
970
978
  __proto__: null,
971
- create: create$9
979
+ create: create$d
972
980
  };
973
981
  const create$2 = async ({
974
982
  commandMap
@@ -1044,8 +1052,7 @@ const RendererWorker = {
1044
1052
  __proto__: null,
1045
1053
  invoke: invoke$3,
1046
1054
  invokeAndTransfer: invokeAndTransfer$3,
1047
- set: set$3
1048
- };
1055
+ set: set$3};
1049
1056
 
1050
1057
  const {
1051
1058
  set: set$1,
@@ -2012,19 +2019,23 @@ const focusNext$7 = async () => {
2012
2019
  const selectUp = async () => {
2013
2020
  await invoke('Explorer.selectUp');
2014
2021
  };
2022
+ const handleDragOverIndex = async index => {
2023
+ // @ts-ignore
2024
+ await invoke('Explorer.handleDragOverIndex', index);
2025
+ };
2015
2026
  const selectDown = async () => {
2016
2027
  await invoke('Explorer.selectDown');
2017
2028
  };
2018
2029
  const refresh = async () => {
2019
2030
  await invoke('Explorer.refresh');
2020
2031
  };
2021
- const focusIndex$3 = async index => {
2032
+ const focusIndex$4 = async index => {
2022
2033
  await invoke('Explorer.focusIndex', index);
2023
2034
  };
2024
2035
  const clickCurrent = async () => {
2025
2036
  await invoke('Explorer.handleClickCurrent');
2026
2037
  };
2027
- const handleArrowLeft = async () => {
2038
+ const handleArrowLeft$1 = async () => {
2028
2039
  await invoke('Explorer.handleArrowLeft');
2029
2040
  };
2030
2041
  const focusLast$5 = async () => {
@@ -2048,7 +2059,7 @@ const newFolder = async () => {
2048
2059
  const handleClick$1 = async index => {
2049
2060
  await invoke('Explorer.handleClick', index);
2050
2061
  };
2051
- const handleClickAt$1 = async (preventDefault, button, ctrlKey, shiftKey, x, y) => {
2062
+ const handleClickAt$2 = async (preventDefault, button, ctrlKey, shiftKey, x, y) => {
2052
2063
  // @ts-ignore
2053
2064
  await invoke('Explorer.handleClickAt', preventDefault, button, ctrlKey, shiftKey, x, y);
2054
2065
  };
@@ -2084,6 +2095,10 @@ const handleCut = async () => {
2084
2095
  // @ts-ignore
2085
2096
  await invoke('Explorer.handleCut');
2086
2097
  };
2098
+ const handleCopy = async () => {
2099
+ // @ts-ignore
2100
+ await invoke('Explorer.handleCopy');
2101
+ };
2087
2102
  const handlePaste = async () => {
2088
2103
  // @ts-ignore
2089
2104
  await invoke('Explorer.handlePaste');
@@ -2091,6 +2106,10 @@ const handlePaste = async () => {
2091
2106
  const selectIndices = async indices => {
2092
2107
  await invoke('Explorer.selectIndices', indices);
2093
2108
  };
2109
+ const toggleIndividualSelection = async index => {
2110
+ // @ts-ignore
2111
+ await invoke('Explorer.toggleIndividualSelection', index);
2112
+ };
2094
2113
 
2095
2114
  const TestFrameWorkComponentExplorer = {
2096
2115
  __proto__: null,
@@ -2101,16 +2120,18 @@ const TestFrameWorkComponentExplorer = {
2101
2120
  expandRecursively,
2102
2121
  focus: focus$1,
2103
2122
  focusFirst: focusFirst$6,
2104
- focusIndex: focusIndex$3,
2123
+ focusIndex: focusIndex$4,
2105
2124
  focusLast: focusLast$5,
2106
2125
  focusNext: focusNext$7,
2107
- handleArrowLeft,
2126
+ handleArrowLeft: handleArrowLeft$1,
2108
2127
  handleBlur,
2109
2128
  handleClick: handleClick$1,
2110
- handleClickAt: handleClickAt$1,
2129
+ handleClickAt: handleClickAt$2,
2130
+ handleCopy,
2111
2131
  handleCut,
2112
2132
  handleDragLeave,
2113
2133
  handleDragOver,
2134
+ handleDragOverIndex,
2114
2135
  handleDrop,
2115
2136
  handleInputBlur,
2116
2137
  handlePaste,
@@ -2125,6 +2146,7 @@ const TestFrameWorkComponentExplorer = {
2125
2146
  selectDown,
2126
2147
  selectIndices,
2127
2148
  selectUp,
2149
+ toggleIndividualSelection,
2128
2150
  updateEditingValue
2129
2151
  };
2130
2152
 
@@ -2155,10 +2177,27 @@ const open$4 = extensionId => {
2155
2177
  const uri = `extension-detail://${extensionId}`;
2156
2178
  return invoke('Main.openUri', uri);
2157
2179
  };
2180
+ const openFeature = featureName => {
2181
+ // @ts-ignore
2182
+ return invoke('ExtensionDetail.handleFeaturesClick', featureName);
2183
+ };
2184
+ const openThemes = async () => {
2185
+ await openFeature('Themes');
2186
+ };
2187
+ const openCommands = async () => {
2188
+ await openFeature('Commands');
2189
+ };
2190
+ const openWebViews = async () => {
2191
+ await openFeature('WebView');
2192
+ };
2158
2193
 
2159
2194
  const TestFrameWorkComponentExtensionDetail = {
2160
2195
  __proto__: null,
2161
2196
  open: open$4,
2197
+ openCommands,
2198
+ openFeature,
2199
+ openThemes,
2200
+ openWebViews,
2162
2201
  selectFeature,
2163
2202
  selectTab
2164
2203
  };
@@ -2531,10 +2570,55 @@ const show = async () => {
2531
2570
  // @ts-ignore
2532
2571
  await invoke('Panel.selectIndex', 0);
2533
2572
  };
2573
+ const handleFilterInput = async text => {
2574
+ // @ts-ignore
2575
+ await invoke('Problems.handleFilterInput', text);
2576
+ };
2577
+ const copyMessage = async () => {
2578
+ // @ts-ignore
2579
+ await invoke('Problems.copyMessage');
2580
+ };
2581
+ const focusIndex$3 = async index => {
2582
+ // @ts-ignore
2583
+ await invoke('Problems.focusIndex', index);
2584
+ };
2585
+ const handleArrowLeft = async () => {
2586
+ // @ts-ignore
2587
+ await invoke('Problems.handleArrowLeft');
2588
+ };
2589
+ const handleArrowRight = async () => {
2590
+ // @ts-ignore
2591
+ await invoke('Problems.handleArrowRight');
2592
+ };
2593
+ const handleClickAt$1 = async (x, y) => {
2594
+ // @ts-ignore
2595
+ await invoke('Problems.handleClickAt', x, y);
2596
+ };
2597
+ const handleIconThemeChange = async () => {
2598
+ // @ts-ignore
2599
+ await invoke('Problems.handleIconThemeChange');
2600
+ };
2601
+ const viewAsList = async () => {
2602
+ // @ts-ignore
2603
+ await invoke('Problems.viewAsList');
2604
+ };
2605
+ const viewAsTable = async () => {
2606
+ // @ts-ignore
2607
+ await invoke('Problems.viewAsTable');
2608
+ };
2534
2609
 
2535
2610
  const TestFrameWorkComponentProblems = {
2536
2611
  __proto__: null,
2537
- show
2612
+ copyMessage,
2613
+ focusIndex: focusIndex$3,
2614
+ handleArrowLeft,
2615
+ handleArrowRight,
2616
+ handleClickAt: handleClickAt$1,
2617
+ handleFilterInput,
2618
+ handleIconThemeChange,
2619
+ show,
2620
+ viewAsList,
2621
+ viewAsTable
2538
2622
  };
2539
2623
 
2540
2624
  const QuickPick = 'QuickPick';
@@ -2890,6 +2974,20 @@ const TestFrameWorkComponentTitleBarMenuBar = {
2890
2974
  toggleMenu
2891
2975
  };
2892
2976
 
2977
+ let url = '';
2978
+ const setUrl = newUrl => {
2979
+ url = newUrl;
2980
+ };
2981
+ const resolve = relativePath => {
2982
+ return new URL(relativePath, url).toString();
2983
+ };
2984
+
2985
+ const TestFrameWorkComponentUrl = {
2986
+ __proto__: null,
2987
+ resolve,
2988
+ setUrl
2989
+ };
2990
+
2893
2991
  const getPortTuple = () => {
2894
2992
  const {
2895
2993
  port1,
@@ -2964,9 +3062,15 @@ const TestFrameWorkComponentWebView = {
2964
3062
  const setPath = async path => {
2965
3063
  await invoke('Workspace.setPath', path);
2966
3064
  };
3065
+ const openTmpDir = async () => {
3066
+ const tmpDir = await getTmpDir();
3067
+ await setPath(tmpDir);
3068
+ return tmpDir;
3069
+ };
2967
3070
 
2968
3071
  const TestFrameWorkComponentWorkspace = {
2969
3072
  __proto__: null,
3073
+ openTmpDir,
2970
3074
  setPath
2971
3075
  };
2972
3076
 
@@ -3002,6 +3106,7 @@ const TestFrameWorkComponent = {
3002
3106
  SourceControl: TestFrameWorkComponentSourceControl,
3003
3107
  StatusBar: TestFrameWorkComponentStatusBar,
3004
3108
  TitleBarMenuBar: TestFrameWorkComponentTitleBarMenuBar,
3109
+ Url: TestFrameWorkComponentUrl,
3005
3110
  WebView: TestFrameWorkComponentWebView,
3006
3111
  Workspace: TestFrameWorkComponentWorkspace
3007
3112
  };
@@ -3015,6 +3120,7 @@ const execute = async href => {
3015
3120
  // 0. wait for page to be ready
3016
3121
  // 1. get script to import from renderer process (url or from html)
3017
3122
  const scriptUrl = href;
3123
+ setUrl(scriptUrl);
3018
3124
  // 2. import that script
3019
3125
  const module = await importTest(scriptUrl);
3020
3126
  if (module.mockRpc) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/test-worker",
3
- "version": "4.27.0",
3
+ "version": "4.29.0",
4
4
  "description": "Test Worker",
5
5
  "repository": {
6
6
  "type": "git",