@@ -4,47 +4,47 @@ import { promises as fs } from 'node:fs';
44import os from 'node:os' ;
55import path from 'node:path' ;
66
7- vi . mock ( '../../../utils/exec.ts' , async ( importOriginal ) => {
8- const actual = await importOriginal < typeof import ( '../../../utils/exec.ts' ) > ( ) ;
7+ vi . mock ( '../../../../ utils/exec.ts' , async ( importOriginal ) => {
8+ const actual = await importOriginal < typeof import ( '../../../../ utils/exec.ts' ) > ( ) ;
99 return { ...actual , runCmd : vi . fn ( actual . runCmd ) } ;
1010} ) ;
11- vi . mock ( '../../../utils/retry.ts' , async ( importOriginal ) => {
12- const actual = await importOriginal < typeof import ( '../../../utils/retry.ts' ) > ( ) ;
11+ vi . mock ( '../../../../ utils/retry.ts' , async ( importOriginal ) => {
12+ const actual = await importOriginal < typeof import ( '../../../../ utils/retry.ts' ) > ( ) ;
1313 return { ...actual , retryWithPolicy : vi . fn ( actual . retryWithPolicy ) } ;
1414} ) ;
15- vi . mock ( '../../apple/core/ runner/runner-client.ts' , async ( importOriginal ) => {
16- const actual = await importOriginal < typeof import ( '../../apple/core/ runner/runner-client.ts' ) > ( ) ;
15+ vi . mock ( '../runner/runner-client.ts' , async ( importOriginal ) => {
16+ const actual = await importOriginal < typeof import ( '../runner/runner-client.ts' ) > ( ) ;
1717 return { ...actual , runIosRunnerCommand : vi . fn ( actual . runIosRunnerCommand ) } ;
1818} ) ;
19- vi . mock ( '../../apple/core/ simulator.ts' , async ( importOriginal ) => {
20- const actual = await importOriginal < typeof import ( '../../apple/core/ simulator.ts' ) > ( ) ;
19+ vi . mock ( '../simulator.ts' , async ( importOriginal ) => {
20+ const actual = await importOriginal < typeof import ( '../simulator.ts' ) > ( ) ;
2121 return {
2222 ...actual ,
2323 ensureBootedSimulator : vi . fn ( actual . ensureBootedSimulator ) ,
2424 openIosSimulatorApp : vi . fn ( actual . openIosSimulatorApp ) ,
2525 } ;
2626} ) ;
27- vi . mock ( '../../apple/core/ screenshot-status-bar.ts' , async ( importOriginal ) => {
28- const actual = await importOriginal < typeof import ( '../../apple/core/ screenshot-status-bar.ts' ) > ( ) ;
27+ vi . mock ( '../screenshot-status-bar.ts' , async ( importOriginal ) => {
28+ const actual = await importOriginal < typeof import ( '../screenshot-status-bar.ts' ) > ( ) ;
2929 return {
3030 ...actual ,
3131 prepareSimulatorStatusBarForScreenshot : vi . fn ( actual . prepareSimulatorStatusBarForScreenshot ) ,
3232 } ;
3333} ) ;
3434
35- const execActual =
36- await vi . importActual < typeof import ( '../../../utils/exec.ts' ) > ( '../../../utils/exec.ts' ) ;
37- const retryActual =
38- await vi . importActual < typeof import ( '../../../utils/retry.ts' ) > ( '../../../utils/retry.ts' ) ;
39- const runnerActual = await vi . importActual <
40- typeof import ( '../../apple/core/runner/runner-client.ts' )
41- > ( '../../apple/core/runner/runner-client.ts' ) ;
42- const simulatorActual = await vi . importActual < typeof import ( '../../apple/core/simulator.ts' ) > (
43- '../../apple/core/simulator.ts' ,
35+ const execActual = await vi . importActual < typeof import ( '../../../../utils/exec.ts' ) > (
36+ '../../../../utils/exec.ts' ,
4437) ;
38+ const retryActual = await vi . importActual < typeof import ( '../../../../utils/retry.ts' ) > (
39+ '../../../../utils/retry.ts' ,
40+ ) ;
41+ const runnerActual = await vi . importActual < typeof import ( '../runner/runner-client.ts' ) > (
42+ '../runner/runner-client.ts' ,
43+ ) ;
44+ const simulatorActual = await vi . importActual < typeof import ( '../simulator.ts' ) > ( '../simulator.ts' ) ;
4545const screenshotStatusBarActual = await vi . importActual <
46- typeof import ( '../../apple/core/ screenshot-status-bar.ts' )
47- > ( '../../apple/core/ screenshot-status-bar.ts' ) ;
46+ typeof import ( '../screenshot-status-bar.ts' )
47+ > ( '../screenshot-status-bar.ts' ) ;
4848
4949import {
5050 closeIosApp ,
@@ -60,36 +60,30 @@ import {
6060 setIosSetting ,
6161 shouldFallbackToRunnerForIosScreenshot ,
6262 shouldRetryIosSimulatorScreenshot ,
63- } from '../../apple/core/ apps.ts' ;
63+ } from '../apps.ts' ;
6464import { withMockedMacOsHelper } from './macos-helper-test-utils.ts' ;
65- import { quitMacOsApp , resolveMacOsHelperPackageRootFrom } from '../../apple/ os/macos/helper.ts' ;
65+ import { quitMacOsApp , resolveMacOsHelperPackageRootFrom } from '../../os/macos/helper.ts' ;
6666import {
6767 captureSimulatorScreenshotWithFallback ,
6868 captureSimulatorScreenshotWithRetry ,
6969 captureScreenshotViaRunner ,
7070 prepareSimulatorStatusBarForScreenshot ,
7171 resolveSimulatorRunnerScreenshotCandidatePaths ,
72- } from '../../apple/core/ screenshot.ts' ;
73- import { ensureBootedSimulator , openIosSimulatorApp } from '../../apple/core/ simulator.ts' ;
72+ } from '../screenshot.ts' ;
73+ import { ensureBootedSimulator , openIosSimulatorApp } from '../simulator.ts' ;
7474import {
7575 invalidateSimulatorStatusBarOverrideCache ,
7676 prepareSimulatorStatusBarForScreenshot as prepareStatusBarForScreenshot ,
77- } from '../../apple/core/screenshot-status-bar.ts' ;
78- import { runIosRunnerCommand } from '../../apple/core/runner/runner-client.ts' ;
79- import { iosRunnerOverrides } from '../interactions.ts' ;
80- import {
81- IOS_DEVICE_INSTALL_TIMEOUT_MS ,
82- IOS_SIMULATOR_TERMINATE_TIMEOUT_MS ,
83- } from '../../apple/core/config.ts' ;
84- import type { DeviceInfo } from '../../../kernel/device.ts' ;
85- import { withDiagnosticsScope } from '../../../utils/diagnostics.ts' ;
86- import { AppError } from '../../../kernel/errors.ts' ;
87- import { runCmd } from '../../../utils/exec.ts' ;
88- import { retryWithPolicy } from '../../../utils/retry.ts' ;
89- import {
90- parseIosDeviceAppsPayload ,
91- parseIosDeviceProcessesPayload ,
92- } from '../../apple/core/devicectl.ts' ;
77+ } from '../screenshot-status-bar.ts' ;
78+ import { runIosRunnerCommand } from '../runner/runner-client.ts' ;
79+ import { iosRunnerOverrides } from '../../../ios/interactions.ts' ;
80+ import { IOS_DEVICE_INSTALL_TIMEOUT_MS , IOS_SIMULATOR_TERMINATE_TIMEOUT_MS } from '../config.ts' ;
81+ import type { DeviceInfo } from '../../../../kernel/device.ts' ;
82+ import { withDiagnosticsScope } from '../../../../utils/diagnostics.ts' ;
83+ import { AppError } from '../../../../kernel/errors.ts' ;
84+ import { runCmd } from '../../../../utils/exec.ts' ;
85+ import { retryWithPolicy } from '../../../../utils/retry.ts' ;
86+ import { parseIosDeviceAppsPayload , parseIosDeviceProcessesPayload } from '../devicectl.ts' ;
9387
9488const IOS_TEST_DEVICE : DeviceInfo = {
9589 platform : 'ios' ,
0 commit comments