@lvce-editor/test-worker 4.42.0 → 4.44.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 +14 -12
- package/dist/testWorkerMain.js +15 -2
- package/package.json +1 -1
package/dist/api.d.ts
CHANGED
|
@@ -19,6 +19,7 @@ declare const readNativeFiles: () => Promise<void>;
|
|
|
19
19
|
declare const writeNativeFiles: (uris: readonly string[]) => Promise<void>;
|
|
20
20
|
declare const enableMemoryClipBoard: () => Promise<void>;
|
|
21
21
|
declare const disableMemoryClipBoard: () => Promise<void>;
|
|
22
|
+
declare const shouldHaveText: (expectedText: string) => Promise<void>;
|
|
22
23
|
declare const execute: (id: string, ...args: readonly any[]) => Promise<any>;
|
|
23
24
|
declare const selectItem: (text: string) => Promise<void>;
|
|
24
25
|
declare const openIframeInspector: () => Promise<void>;
|
|
@@ -87,7 +88,7 @@ declare const openRename: () => Promise<void>;
|
|
|
87
88
|
declare const rename2: (newName: string) => Promise<void>;
|
|
88
89
|
declare const growSelection: () => Promise<void>;
|
|
89
90
|
declare const getSelections: () => Promise<Uint32Array>;
|
|
90
|
-
declare const shouldHaveText: (expectedText: string) => Promise<void>;
|
|
91
|
+
declare const shouldHaveText$1: (expectedText: string) => Promise<void>;
|
|
91
92
|
declare const shouldHaveSelections: (expectedSelections: Uint32Array) => Promise<void>;
|
|
92
93
|
declare const selectIndex: (index: number) => Promise<void>;
|
|
93
94
|
declare const selectCurrentIndex: () => Promise<void>;
|
|
@@ -171,6 +172,7 @@ declare const handleDoubleClick: (x: number, y: number) => Promise<void>;
|
|
|
171
172
|
declare const focusNext$5: () => Promise<void>;
|
|
172
173
|
declare const focusPrevious$3: () => Promise<void>;
|
|
173
174
|
declare const focusFirst$3: () => Promise<void>;
|
|
175
|
+
declare const focusIndex$1: (index: number) => Promise<void>;
|
|
174
176
|
declare const focusLast$3: () => Promise<void>;
|
|
175
177
|
declare const toggleRecordingKeys: () => Promise<void>;
|
|
176
178
|
declare const startRecordingKeys: () => Promise<void>;
|
|
@@ -209,7 +211,7 @@ declare const isFirefox: () => boolean;
|
|
|
209
211
|
declare const show$2: () => Promise<void>;
|
|
210
212
|
declare const handleFilterInput$1: (text: string) => Promise<void>;
|
|
211
213
|
declare const copyMessage: () => Promise<void>;
|
|
212
|
-
declare const focusIndex$
|
|
214
|
+
declare const focusIndex$2: (index: number) => Promise<void>;
|
|
213
215
|
declare const handleArrowLeft$1: () => Promise<void>;
|
|
214
216
|
declare const handleArrowRight: () => Promise<void>;
|
|
215
217
|
declare const handleClickAt$1: (x: number, y: number) => Promise<void>;
|
|
@@ -223,7 +225,7 @@ declare const setValue$1: (value: string) => Promise<void>;
|
|
|
223
225
|
declare const focusNext$7: () => Promise<void>;
|
|
224
226
|
declare const focusFirst$5: () => Promise<void>;
|
|
225
227
|
declare const focusLast$5: () => Promise<void>;
|
|
226
|
-
declare const focusIndex$
|
|
228
|
+
declare const focusIndex$3: (index: number) => Promise<void>;
|
|
227
229
|
declare const focusPrevious$5: () => Promise<void>;
|
|
228
230
|
declare const selectItem$1: (label: string) => Promise<void>;
|
|
229
231
|
declare const selectIndex$3: (index: number) => Promise<void>;
|
|
@@ -247,7 +249,7 @@ declare const openDetails: () => Promise<void>;
|
|
|
247
249
|
declare const collapseDetails: () => Promise<void>;
|
|
248
250
|
declare const dismissItem: () => Promise<void>;
|
|
249
251
|
declare const focusFirst$6: () => Promise<void>;
|
|
250
|
-
declare const focusIndex$
|
|
252
|
+
declare const focusIndex$4: (index: number) => Promise<void>;
|
|
251
253
|
declare const selectIndex$5: (index: number) => Promise<void>;
|
|
252
254
|
declare const focusNext$8: () => Promise<void>;
|
|
253
255
|
declare const handleWheel$1: (deltaMode: number, deltaY: number) => Promise<void>;
|
|
@@ -281,7 +283,7 @@ declare const update$1: () => Promise<void>;
|
|
|
281
283
|
declare const closeMenu: () => Promise<void>;
|
|
282
284
|
declare const focus$2: () => Promise<void>;
|
|
283
285
|
declare const focusFirst$7: () => Promise<void>;
|
|
284
|
-
declare const focusIndex$
|
|
286
|
+
declare const focusIndex$5: (index: number) => Promise<void>;
|
|
285
287
|
declare const focusLast$6: () => Promise<void>;
|
|
286
288
|
declare const focusNext$9: () => Promise<void>;
|
|
287
289
|
declare const focusPrevious$7: () => Promise<void>;
|
|
@@ -314,7 +316,7 @@ declare namespace BaseUrl {
|
|
|
314
316
|
export { getBaseUrl };
|
|
315
317
|
}
|
|
316
318
|
declare namespace ClipBoard {
|
|
317
|
-
export { disableMemoryClipBoard, enableMemoryClipBoard, readNativeFiles, writeNativeFiles };
|
|
319
|
+
export { disableMemoryClipBoard, enableMemoryClipBoard, readNativeFiles, shouldHaveText, writeNativeFiles };
|
|
318
320
|
}
|
|
319
321
|
declare namespace Command {
|
|
320
322
|
export { execute };
|
|
@@ -329,7 +331,7 @@ declare namespace Dialog {
|
|
|
329
331
|
export { executeMock, mockSaveFilePicker, showSaveFilePicker };
|
|
330
332
|
}
|
|
331
333
|
declare namespace Editor {
|
|
332
|
-
export { addAllMissingImports, closeColorPicker, closeCompletion, closeCompletionDetails, copy, copyLineDown, copyLineUp, cursorCharacterLeft, cursorCharacterRight, cursorDown, cursorEnd, cursorHome, cursorUp, cursorWordLeft, cursorWordPartLeft, cursorWordPartRight, cursorWordRight, deleteAllLeft, deleteAllRight, executeTabCompletion, findAllImplementations, findAllReferences, format, getSelections, getText, goToDefinition, goToTypeDefinition, growSelection, insertLineBreak, invokeBraceCompletion, invokeTabCompletion, openColorPicker, openCompletion, openCompletionDetails, openContextMenu, openEditorContextMenu, openFind, openFindWidget, openHover, openRename, openSourceActions, organizeImports, rename, rename2, selectAll, setCursor, setDeltaY, setSelections, shouldHaveSelections, shouldHaveText, showHover, sortImports, sourceActionsSelectCurrent, toggleBlockComment, toggleCompletionDetails, toggleLineComment, type };
|
|
334
|
+
export { addAllMissingImports, closeColorPicker, closeCompletion, closeCompletionDetails, copy, copyLineDown, copyLineUp, cursorCharacterLeft, cursorCharacterRight, cursorDown, cursorEnd, cursorHome, cursorUp, cursorWordLeft, cursorWordPartLeft, cursorWordPartRight, cursorWordRight, deleteAllLeft, deleteAllRight, executeTabCompletion, findAllImplementations, findAllReferences, format, getSelections, getText, goToDefinition, goToTypeDefinition, growSelection, insertLineBreak, invokeBraceCompletion, invokeTabCompletion, openColorPicker, openCompletion, openCompletionDetails, openContextMenu, openEditorContextMenu, openFind, openFindWidget, openHover, openRename, openSourceActions, organizeImports, rename, rename2, selectAll, setCursor, setDeltaY, setSelections, shouldHaveSelections, shouldHaveText$1 as shouldHaveText, showHover, sortImports, sourceActionsSelectCurrent, toggleBlockComment, toggleCompletionDetails, toggleLineComment, type };
|
|
333
335
|
}
|
|
334
336
|
declare namespace EditorCompletion {
|
|
335
337
|
export { selectCurrentIndex, selectIndex };
|
|
@@ -359,7 +361,7 @@ declare namespace IframeInspector {
|
|
|
359
361
|
export { focusFirst$2 as focusFirst, focusLast$2 as focusLast, focusNext$4 as focusNext, focusPrevious$2 as focusPrevious, selectIndex$2 as selectIndex };
|
|
360
362
|
}
|
|
361
363
|
declare namespace KeyBindingsEditor {
|
|
362
|
-
export { addKeyBinding, changeWhenExpression, clearInput, copyCommandId, copyCommandTitle, focusFirst$3 as focusFirst, focusLast$3 as focusLast, focusNext$5 as focusNext, focusPrevious$3 as focusPrevious, handleClick$2 as handleClick, handleContextMenu$1 as handleContextMenu, handleDoubleClick, handleInput, handleWheel, open$1 as open, removeKeyBinding, resetKeyBinding, showSameKeyBindings, sortByPrecedence, startRecordingKeys, stopRecordingKeys, toggleRecordingKeys };
|
|
364
|
+
export { addKeyBinding, changeWhenExpression, clearInput, copyCommandId, copyCommandTitle, focusFirst$3 as focusFirst, focusIndex$1 as focusIndex, focusLast$3 as focusLast, focusNext$5 as focusNext, focusPrevious$3 as focusPrevious, handleClick$2 as handleClick, handleContextMenu$1 as handleContextMenu, handleDoubleClick, handleInput, handleWheel, open$1 as open, removeKeyBinding, resetKeyBinding, showSameKeyBindings, sortByPrecedence, startRecordingKeys, stopRecordingKeys, toggleRecordingKeys };
|
|
363
365
|
}
|
|
364
366
|
declare namespace KeyBoard {
|
|
365
367
|
export { press };
|
|
@@ -377,16 +379,16 @@ declare namespace Platform {
|
|
|
377
379
|
export { getNodePath, isFirefox };
|
|
378
380
|
}
|
|
379
381
|
declare namespace Problems {
|
|
380
|
-
export { copyMessage, focusIndex$
|
|
382
|
+
export { copyMessage, focusIndex$2 as focusIndex, handleArrowLeft$1 as handleArrowLeft, handleArrowRight, handleClickAt$1 as handleClickAt, handleFilterInput$1 as handleFilterInput, handleIconThemeChange, show$2 as show, viewAsList, viewAsTable };
|
|
381
383
|
}
|
|
382
384
|
declare namespace QuickPick {
|
|
383
|
-
export { executeCommand, focusFirst$5 as focusFirst, focusIndex$
|
|
385
|
+
export { executeCommand, focusFirst$5 as focusFirst, focusIndex$3 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$2 as selectCurrentIndex, selectIndex$3 as selectIndex, selectItem$1 as selectItem, setValue$1 as setValue };
|
|
384
386
|
}
|
|
385
387
|
declare namespace RunAndDebug {
|
|
386
388
|
export { acceptWatchExpressionEdit, addWatchExpression, handleClickSectionWatch, handleRename, handleSpace, handleWatchValueChange, selectIndex$4 as selectIndex, setPauseOnExceptions };
|
|
387
389
|
}
|
|
388
390
|
declare namespace Search {
|
|
389
|
-
export { clearSearchResults, collapseDetails, dismissItem, focusFirst$6 as focusFirst, focusIndex$
|
|
391
|
+
export { clearSearchResults, collapseDetails, dismissItem, focusFirst$6 as focusFirst, focusIndex$4 as focusIndex, focusNext$8 as focusNext, focusNextPage, focusPrevious$6 as focusPrevious, focusPreviousPage, handleWheel$1 as handleWheel, openDetails, replaceAll, selectIndex$5 as selectIndex, setExcludeValue, setIncludeValue, setReplaceValue, setValue$2 as setValue, toggleMatchCase, toggleMatchWholeWord, togglePreserveCase, toggleReplace, toggleSearchDetails, toggleUseRegularExpression };
|
|
390
392
|
}
|
|
391
393
|
declare namespace Settings {
|
|
392
394
|
export { update };
|
|
@@ -404,7 +406,7 @@ declare namespace StatusBar {
|
|
|
404
406
|
export { update$1 as update };
|
|
405
407
|
}
|
|
406
408
|
declare namespace TitleBarMenuBar {
|
|
407
|
-
export { closeMenu, focus$2 as focus, focusFirst$7 as focusFirst, focusIndex$
|
|
409
|
+
export { closeMenu, focus$2 as focus, focusFirst$7 as focusFirst, focusIndex$5 as focusIndex, focusLast$6 as focusLast, focusNext$9 as focusNext, focusPrevious$7 as focusPrevious, handleKeyArrowDown, handleKeyArrowLeft, handleKeyArrowRight, handleKeyArrowUp, handleKeyEnd, handleKeyEscape, handleKeyHome, handleKeySpace, toggleIndex, toggleMenu };
|
|
408
410
|
}
|
|
409
411
|
declare namespace Url {
|
|
410
412
|
export { resolve, setUrl };
|
package/dist/testWorkerMain.js
CHANGED
|
@@ -1744,12 +1744,20 @@ const disableMemoryClipBoard = async () => {
|
|
|
1744
1744
|
// @ts-ignore
|
|
1745
1745
|
await invoke$1('ClipBoard.disableMemoryClipBoard');
|
|
1746
1746
|
};
|
|
1747
|
+
const shouldHaveText$1 = async expectedText => {
|
|
1748
|
+
// @ts-ignore
|
|
1749
|
+
const actualText = await invoke$1('ClipBoard.readMemoryText');
|
|
1750
|
+
if (actualText !== expectedText) {
|
|
1751
|
+
throw new AssertionError(`expected clipboard to have text "${expectedText}" but was "${actualText}"`);
|
|
1752
|
+
}
|
|
1753
|
+
};
|
|
1747
1754
|
|
|
1748
1755
|
const TestFrameworkComponentClipBoard = {
|
|
1749
1756
|
__proto__: null,
|
|
1750
1757
|
disableMemoryClipBoard,
|
|
1751
1758
|
enableMemoryClipBoard,
|
|
1752
1759
|
readNativeFiles,
|
|
1760
|
+
shouldHaveText: shouldHaveText$1,
|
|
1753
1761
|
writeNativeFiles
|
|
1754
1762
|
};
|
|
1755
1763
|
|
|
@@ -2213,7 +2221,7 @@ const selectDown = async () => {
|
|
|
2213
2221
|
const refresh = async () => {
|
|
2214
2222
|
await invoke$1('Explorer.refresh');
|
|
2215
2223
|
};
|
|
2216
|
-
const focusIndex$
|
|
2224
|
+
const focusIndex$5 = async index => {
|
|
2217
2225
|
await invoke$1('Explorer.focusIndex', index);
|
|
2218
2226
|
};
|
|
2219
2227
|
const clickCurrent = async () => {
|
|
@@ -2304,7 +2312,7 @@ const TestFrameWorkComponentExplorer = {
|
|
|
2304
2312
|
expandRecursively,
|
|
2305
2313
|
focus: focus$1,
|
|
2306
2314
|
focusFirst: focusFirst$6,
|
|
2307
|
-
focusIndex: focusIndex$
|
|
2315
|
+
focusIndex: focusIndex$5,
|
|
2308
2316
|
focusLast: focusLast$5,
|
|
2309
2317
|
focusNext: focusNext$7,
|
|
2310
2318
|
handleArrowLeft: handleArrowLeft$1,
|
|
@@ -2570,6 +2578,10 @@ const focusPrevious$4 = () => {
|
|
|
2570
2578
|
const focusFirst$4 = () => {
|
|
2571
2579
|
return invoke$1('KeyBindings.focusFirst');
|
|
2572
2580
|
};
|
|
2581
|
+
const focusIndex$4 = index => {
|
|
2582
|
+
// @ts-ignore
|
|
2583
|
+
return invoke$1('KeyBindings.focusIndex', index);
|
|
2584
|
+
};
|
|
2573
2585
|
const focusLast$3 = () => {
|
|
2574
2586
|
return invoke$1('KeyBindings.focusLast');
|
|
2575
2587
|
};
|
|
@@ -2621,6 +2633,7 @@ const TestFrameWorkComponentKeyBindingsEditor = {
|
|
|
2621
2633
|
copyCommandId,
|
|
2622
2634
|
copyCommandTitle,
|
|
2623
2635
|
focusFirst: focusFirst$4,
|
|
2636
|
+
focusIndex: focusIndex$4,
|
|
2624
2637
|
focusLast: focusLast$3,
|
|
2625
2638
|
focusNext: focusNext$4,
|
|
2626
2639
|
focusPrevious: focusPrevious$4,
|