(params: {
command: string;
baseReq: ReplayBaseRequest;
positionals: string[];
scope: ReplayVarScope;
line: number;
step: number;
invoke: DaemonInvokeFn;
invokeReplayAction: MaestroReplayInvoker;
})
| 23 | } from './runtime-interactions.ts'; |
| 24 | |
| 25 | export async function invokeMaestroRuntimeCommand(params: { |
| 26 | command: string; |
| 27 | baseReq: ReplayBaseRequest; |
| 28 | positionals: string[]; |
| 29 | scope: ReplayVarScope; |
| 30 | line: number; |
| 31 | step: number; |
| 32 | invoke: DaemonInvokeFn; |
| 33 | invokeReplayAction: MaestroReplayInvoker; |
| 34 | }): Promise<DaemonResponse | undefined> { |
| 35 | switch (params.command) { |
| 36 | case MAESTRO_RUNTIME_COMMAND.assertVisible: |
| 37 | return await invokeMaestroAssertVisible(params); |
| 38 | case MAESTRO_RUNTIME_COMMAND.assertNotVisible: |
| 39 | return await invokeMaestroAssertNotVisible(params); |
| 40 | case MAESTRO_RUNTIME_COMMAND.pressEnter: |
| 41 | return await invokeMaestroPressEnter(params); |
| 42 | case MAESTRO_RUNTIME_COMMAND.waitForAnimationToEnd: |
| 43 | return await invokeMaestroWaitForAnimationToEnd(params); |
| 44 | case MAESTRO_RUNTIME_COMMAND.scrollUntilVisible: |
| 45 | return await invokeMaestroScrollUntilVisible(params); |
| 46 | case MAESTRO_RUNTIME_COMMAND.swipeScreen: |
| 47 | return await invokeMaestroSwipeScreen(params); |
| 48 | case MAESTRO_RUNTIME_COMMAND.swipeOn: |
| 49 | return await invokeMaestroSwipeOn(params); |
| 50 | case MAESTRO_RUNTIME_COMMAND.tapOn: |
| 51 | return await invokeMaestroTapOn(params); |
| 52 | case MAESTRO_RUNTIME_COMMAND.tapPointPercent: |
| 53 | return await invokeMaestroTapPointPercent(params); |
| 54 | case MAESTRO_RUNTIME_COMMAND.runScript: |
| 55 | return invokeMaestroRunScript(params); |
| 56 | default: |
| 57 | return undefined; |
| 58 | } |
| 59 | } |
| 60 | |
| 61 | async function invokeMaestroPressEnter(params: { |
| 62 | baseReq: ReplayBaseRequest; |
no test coverage detected
searching dependent graphs…