Skip to content

EditorTestHandle beta ​

TypeAlias of @v12-engine/editor/testing

ts
export type EditorTestHandle = Pick<EditorClient, 'addGroundLayer' | 'addTheme' | 'animationFiles' | 'applyEnvironment' | 'askReplace' | 'brushPresets' | 'camera' | 'campaign' | 'changed' | 'checks' | 'cinematics' | 'clipboard' | 'contextMenus' | 'debugView' | 'debugViewShown' | 'detail' | 'dock' | 'edit' | 'doc' | 'editorState' | 'engine' | 'extensions' | 'file' | 'files' | 'groundFromTexture' | 'history' | 'importFiles' | 'inspectModel' | 'inspectModelOf' | 'inspecting' | 'inspector' | 'keys' | 'kinds' | 'logs' | 'framing' | 'map' | 'mapFiles' | 'modelAnatomy' | 'newMap' | 'objectives' | 'overview' | 'code' | 'data' | 'run' | 'changes' | 'open' | 'modelBytes' | 'openAssets' | 'overlays' | 'pack' | 'paintCells' | 'panels' | 'perf' | 'pin' | 'pingHere' | 'playRevealed' | 'playState' | 'playing' | 'plays' | 'prefabFiles' | 'prefs' | 'previewPicture' | 'problems' | 'redo' | 'registry' | 'removeTheme' | 'rules' | 'languages' | 'save' | 'say' | 'scene' | 'screen' | 'search' | 'selectTargets' | 'selection' | 'setName' | 'setPrefs' | 'setTool' | 'shared' | 'shell' | 'sounds' | 'statistics' | 'styles' | 'templates' | 'versions' | 'viewPicture' | 'status' | 'statusInfo' | 'takeFile' | 'tiles' | 'toggleOverlay' | 'tool' | 'transformSelection' | 'undo' | 'view' | 'world'> & {
    readonly played: GameTestHandle | undefined;
};

What a browser test reaches of the editor (EditorTestHandles.editor): the members the specs ask for, by name, and the game played in it. What a spec looks at inside the editor (its parts kept out of its published types) is the spec's own to name, against the editor's source