GameTestHandle beta
TypeAlias of @v12-engine/client/testing
ts
export type GameTestHandle = Pick<GameClient, 'camera' | 'cellLayers' | 'cinematics' | 'controller' | 'debugTools' | 'debugView' | 'detail' | 'dialog' | 'doodads' | 'firstSeen' | 'floats' | 'foliage' | 'follow' | 'followedId' | 'frozen' | 'fx' | 'hoverEveryFrame' | 'hud' | 'lights' | 'looks' | 'mapDecals' | 'mapEnvironment' | 'mapFx' | 'maxFps' | 'menu' | 'on' | 'outline' | 'pace' | 'picture' | 'pings' | 'playClip' | 'portraits' | 'project' | 'quality' | 'renderScale' | 'renderer' | 'score' | 'screenPass' | 'seeThrough' | 'setDialogLook' | 'settings' | 'sounds' | 'state' | 'stopClip' | 'teamColors' | 'transitionPass' | 'ui' | 'unitHud' | 'view' | 'warm' | 'warmed' | 'wind' | 'words' | 'world'> & {
readonly session: LocalSession;
readonly audio: GameClient['audio'];
readonly canvas: GameClient['canvas'];
readonly talk: GameClient['talk'];
readonly hud: ClientHud;
};What a browser test reaches of the game on its page (X9): the members the specs ask for, by name, so that a member renamed or made private in GameClient fails the build of the test handle, not a spec at runtime. The few parts the specs look inside that the client keeps to itself (the canvas, the minimap, the daylight...) are named here too: a test that reads them says so