VSCode extension
The vscode-fleetest extension surfaces scenarios in the Test Explorer (VSCode's Testing view), and adds device
control, live inspection and result review around them. It works by spawning the same fleetest
CLI used from the terminal, so behavior matches the CLI and MCP entry points.
Test Explorer
Scenarios appear in the Test Explorer as a folder → class → @Test method tree, built from
TestProjects/<project>/scenarios/**/*.swift. The target <project> comes from the
fleetest.project setting; when it is empty the extension auto-resolves it, creating
TestProjects/project1/ on startup with fleetest project create project1 if it is missing and selecting
that project1 project initially (see Creating a project). Each test
item can be run in three ways:
- Run — executes the scenario on a device.
- Run (dry-run) — validates the scenario without a device (selector syntax, unreachable
scenes, assertion-less expectations, unknown
#ids from a saved snapshot). - Debug — runs under a Debug Adapter Protocol adapter: set a breakpoint on a command line
inside an
action { }block, then step over, continue, or stop from the debug toolbar.
Setting fleetest.profile routes Run/Run (dry-run)/Debug through fleetest api run --profile <name> instead of the raw fleetest.platform/fleetest.port/fleetest.serial settings — devices
are provisioned (a Simulator / Emulator that is not running is booted; a physical device cannot be booted,
so connect and prepare it yourself) and the app is auto-installed by the run profile; Run (dry-run) needs no device at all.
Run and Debug need a run profile (Run (dry-run) does not). If none is selected and the project has exactly one
run profile, that one is saved to fleetest.profile and the run proceeds; with two or more, the run does not start
and shows an error with a "Select run profile" button.
Steps View
A read-only fleetest Steps tree view (in the Test Explorer) follows the cursor: put
the cursor inside a @Test method and it lists that scenario's scene groups and steps.
Clicking a step jumps to the matching source line. It also opens from a scenario's right-click
menu ("fleetest: Show Step List").
Device Monitor
Command "fleetest: Show Device Monitor" (or fleetest in the status bar at the
bottom of VSCode) opens a webview panel of device tiles (one panel per
workspace). Each tile shows the device name, a platform badge (iOS/Android), a status badge, and
the current screen — streamed live by default via a headless helper
(fleetest-simstream/fleetest-androidstream), falling back to periodic screenshots if streaming
is unavailable.
Turning on Use polling mode in the Settings tab switches from streaming back to the classic
polling (screenshots at a fixed interval); the choice is remembered per workspace.
- Status badges: Connected (green) — bridge attached, ready to drive; Starting (yellow) — device is up but the bridge hasn't attached yet; Not started (gray) — device is down.
- Right-click a tile to start or stop that one device (
fleetest api start-device/stop-device). Device operations run one at a time through a shared queue, so queued tiles show a "Waiting..." badge. - Toolbar buttons start/stop every device in view and restart the monitor process.
- The toolbar charts (MEM / CPU / GPU / Vision / FM) show the Mac's load and the call counts of image analysis (Vision)
and Foundation Models (FM). When FM becomes unusable, the FM chart turns gray and N/A appears
to its right (hover it for the stopped path, the reason and when it was observed). While it is shown, checks
that use FM (
screenLooksLikeand the FM stage of text visibility check) may not run. When this Mac's hardware video encoder is not working, ⚠︎AVE appears next to it (recording clips are still extracted with the software encoder, which is slower; hover it for the reason and when it was observed). When this Mac's Vision is not working, ⚠︎OCR (text recognition) and/or ⚠︎FP (image feature prints) appear further right. While they are shown, checks that rely on reading text (tapping link text, the OCR stage of text visibility check) and image matching (findImageand the like) cannot be trusted. Hover them for the reason and when it was observed. So far, restarting the Mac has cleared this. Only for a run with the OCR text visibility check (ocrTextVisibilityCheck) turned on: while the OCR model is being compiled (for example on the first run after a rebuild; tens of seconds), the run waits for the compile to finish before starting its first scenario ("Compiling Vision…" appears in the running list). The labels carry each machine's capacity, such asMEM 192(GB) /CPU 24/GPU 76(MEM -until the values arrive). Turning off "Show memory size and core counts" (Device Monitor section of the Settings tab, on by default) shows the bareCPU/GPU/MEM. - The run board under the toolbar (headed "Run status") shows one row per machine — this Mac and every registered
runner machine. A run going on right now appears on its machine's row with "N of M done" and an
estimated time left — not just runs you started, but CLI runs and other people's runs too. Before the
run starts, the row says what it is doing instead of the counts ("Building scenarios…", "Starting device
preparation…", "Starting the servers…", "Building the runner…", "Booting devices…", "Starting the bridge…", "Configuring devices…", "Installing the app…",
"Starting tests…").
When the run records video, the time left is replaced by "Encoding videos 12/48" (clips done / all clips)
while the clips are cut after the last scenario.
The "(3)" right of the run's name is the number of devices running a scenario right now.
Expanding a row lists that machine's devices; clicking a row selects them in the Line View.
Servers you keep up with
fleetest services upshow on their machine's row as "Servers up:" (hover for how to stop them). Servers whose starting process has exited without cleaning up show as "Servers without owner: " (hover for how to remove them). For the few seconds a finished run takes to stop its servers, the row says "Servers stopping: ". - When a script or CI pipeline that starts several runs in turn declares its plan, a job (the list of runs about to be started) appears on the run board.
In the run board header, to the right of the tachometer, you see "N/M runs done", the number of failed runs (❌, only when some failed),
how many of the job's runs are running and waiting, and the elapsed time. With two or more jobs, each job's title comes before its counts.
Hovering over "runs done" lists every run of the job, including the unfinished ones, with its state (passed, failed, running, waiting, …), finished runs first, then running, then waiting.
Hovering over "running" and "waiting" lists just those runs (for runs started with several
--targets, running runs also show their machine). Each list shows up to 30 runs. Beyond that, runs that already finished without failing are left out first (failed and unfinished runs stay), and the number left out is shown at the top. No time left is shown for a job. A job appears when a script declares its planned runs withfleetest job begin(see the CLI) and when you run several targets at once withfleetest run --target … --target …(or a repeated--profile; titledrun). A job disappears whenfleetest job endis called or when the--owner-pidprocess (normally the script that declared it) exits. A job from a run with several--targets disappears when that run ends. While a job is running, the toolbar's "Stop All" is disabled (pressed between runs, it would also stop the devices the next run needs). To make it available again, stop the script that declared the job, or runfleetest job end --id "$FT_JOB_ID"in that shell. - The tachometer to the right of "Run status" in the run board header (shown only while a run is going, for 10 seconds after it ends, and throughout a job, including the gaps between its runs; the LED-bar button in the header shows or hides it) shows how fast the runs on this Mac and the runner machines send operations to devices. The LED bar on the right is the count over the last 3 seconds per second, and the number (actions/s) is the bar's value itself (when the bar is at zero, so is the number). Tapping once a second and nothing else reads 1.0. Only operations sent to a device count — taps, typing, swipes (each swipe of a scroll that searches for an element counts) and the like; screen checks and waits do not, and neither do operations you perform by hand from the monitor. Each segment of the bar is 1 action/s; it rises and falls smoothly like a car tachometer, and the number moves with it. The line on the left is the number over the last 60 seconds and scrolls left once a second like the CPU and GPU charts (it drops to zero with the gauge). Hover over it for a per-machine breakdown.
- The Device Monitor tab is split into three views, top to bottom: the Line View (the row of device tiles), the Grid View (enlarged screens of the selected devices), and the Run Log View (the execution log of the selected devices). Drag a divider to resize, click a view's header to collapse or expand it (the header row always stays visible, wherever you drag).
- Turning off "Use physical devices for tests" (Device Monitor section of the Settings tab, on by default) stops using physical devices for tests (runs skip the physical devices listed in the run profile) and removes them from the Line View (those on this Mac and on runner machines; simulators and emulators stay).
- The Grid View and the Run Log View show only the devices selected in the Line View. Clicking
anywhere on a tile toggles its selection; clicking outside the tiles clears the selection. With
nothing selected both views say "Select a device" (provisioning progress during a run still appears
in the Run Log View). The Run Log View shows logs not only of runs started from VS Code but also of runs started
from the terminal (CLI), by other people, and on runner machines. The view keeps the latest 500 lines per device;
the full record stays in the event logs under
results/runs/. With two or more devices shown in the Grid View, left-dragging a rectangle over them narrows the selection to the devices it covers. In the Line View tiles and the Grid View, a device that is running a scenario shows a lamp (the tachometer's blue on iOS, green on Android) at its top left (left of the machine name). With exactly one device selected, a column to the right of the enlarged screen stacks Back, Home, App Switcher, Zoom in and Zoom out buttons, so you can operate that device in place (Back leaves the single-device view: it restores the selection you had before "Select only this device", or clears the selection if there was none). On the screen, click taps, Command(⌘)+click double-taps, holding 500ms or more long-presses, dragging swipes and Option(⌥)+drag traces the exact finger path ("Double tap" lights up while Command is held, "Trace" while Option is held; keep holding to see its explanation). Next to the enlarged screen you get the same element list (Refresh re-reads it; "Show bounding boxes", next to the device count in the header, overlays frames on the screen; long rows scroll sideways) and operation log, and text to type (Enter sends) sits right below the enlarged screen. Selecting a device does not connect to it, so the element list appears after your first operation or Refresh (or right away when "Show bounding boxes" is on; that switch starts off each time the panel opens). The operation log is kept per device. Its right-hand column shows the DSL line for each operation as you would write it in a scenario; click it to copy. Pressing a button or another operable element gives a selector line (tap("#login")and so on), and the operation column shows that selector too (Tap: Log in("#login")). Pressing a non-interactive element such as a map gives that element's selector line with the pressed point as a comment (the selector form presses the element's centre, which can differ from where you pressed). This happens only when a stable selector can name the element and nothing else sits at its centre. Otherwise, such as an empty spot inside a screen region with buttons at its centre, you get a coordinate line with a trailing comment asking you to replace it with a selector. A double-click on the screen is two taps, so to toggle the selection double-click outside the screen (the device name row or the margin). On a foldable device (the iPhone Duo Simulator or a foldable Android Emulator) Fold and Unfold buttons appear as well (never for physical devices). The operations go to the selected device's resident process; when you select another device it switches over to that device first. - You can operate a device even while it is running a test. Your operations interfere with the run, so use your own judgment. They are recorded in the result of the scenario running at that moment (shown under "Human operations" in the Dashboard and in the report); text you type is not recorded. Operations made between two scenarios belong to neither, so they do not appear in any result.
- The iOS and Android badges in the Line View header (to the right of Live Updates; both on by default) limit which devices appear in all four sections (Running, Device list, Selected devices and Run log). Each badge toggles on its own; you cannot turn both off (pressing the only one that is on swaps to the other). The devices themselves keep running; only the display changes.
- Turning Live Updates (in the Line View header) off stops streaming and capturing every device's screen to reduce the Mac's load. Tiles keep their last frame, dimmed (status keeps updating).
- The Test Sessions tab opens finished runs and shows each scenario's video, a step tree, and the
error list. Runs that were not recorded (run profile
record: false) are listed too, marked "Not recorded", with the step tree and error list. If the Device Monitor tab is showing when a run finishes, the monitor switches to the Test Sessions tab and opens that run's recording as soon as it is ready (it does not switch while another tab is showing, nor for runs without recordings or cancelled runs). Between the last scenario finishing and the switch, "Editing recordings..." is shown to the right of the Run Tests button. The Export Test Results button in the player view's header writes the open session's results to an Excel (.xlsx) file; a dialog lets you choose where to save it. - The Profiles tab lists, creates, copies, renames and deletes test projects themselves, and lists, creates, copies, renames, deletes and edits run/app profiles. A run profile's section shows the union of every run profile's devices with checkboxes (checked = this profile runs it), and its own "Add device" button. Choosing an app profile's Target OS (iOS / Android / Hybrid) hides the fields of the other OS. A run profile inherits the target OS of the app it references and shows only that OS's sections and devices. If devices of another OS are registered, it names them in a warning (they stay in the JSON and are ignored at run time).
- The Settings tab holds display, update, log-and-recording cleanup, and remote machine settings, including the update-check and update actions described below. The Tools section at its top has a "Processes" button that brings up that tab.
- The Processes tab (list and stop fleetest's resident processes) is hidden at startup. Opening it brings its tab up; close it with the tab's ×.
- Right-clicking anywhere does not show the default Cut/Copy/Paste menu (except in text input fields).
Live Control
Touching a device directly from its screenshot. It lives in the Grid View when exactly one device is selected (see above). Selecting a device does not connect to it; the first operation or Refresh does.
If the device's bridge isn't running yet, it is started automatically. An operation made while it starts shows a brief "The device is still getting ready — try again once the screen appears" notice instead of an error — normally this is tens of seconds (reusing an existing build); only the very first build for that device takes longer.
| Gesture | Action |
|---|---|
| Click | Tap |
| Hold ~500ms without moving | Long press (after 500ms the start point turns orange and shows "Long press"; moving on from there is a long-press-then-drag. Not shown while Command (⌘) is held, since releasing double-taps) |
| Drag | Swipe (direction inferred from the drag vector) |
| Option (⌥) + drag | Trace the exact finger path (the toolbar's Trace indicator lights up while Option is held; one continuous touch that never lifts; stopping and then moving while held is a long-press-then-drag (after 500ms still, the "Long press" mark appears; Maps on iOS then drops a pin instead of panning); it replays at the speed you traced; once a trace passes 60 seconds it is cancelled on the spot with an error, and nothing is sent when you release. After you release, while the device replays it, the traced line turns faint and a thick line grows over the part already replayed) |
| Command (⌘) + click | Double tap (the toolbar's Double tap indicator lights up while Command is held) |
| Toolbar zoom in/out | Pinch (whole screen) |
On iOS, double tap (Command (⌘) + click) does not register in a Compose app on a physical device or
in xcuitest mode. To zoom in, use the toolbar's zoom (a pinch) instead
(gestures).
The element list next to the screenshot is for reading: clicking a row does not touch the device. Hovering over a row highlights that element's frame on the screenshot. The text field sends input to whatever the device has focused (tap the field on the screenshot first, then type).
After an operation it waits for the screen to settle, then re-reads the element tree and redraws the frames (it does not re-read while the device is running a test).
You can keep driving the device after the app under test leaves the foreground (iOS). When the home screen, the app switcher, another app or a system dialog comes to the front, Live Control follows whatever is on screen — gestures land on it and the element list shows it. It switches back on its own once the app returns to the front (if it does not, launch the app again).
Results Dashboard
Command "fleetest: Open Results Dashboard" shows, in the Device Monitor's Dashboard tab, a summary of
fleetest api results for the project. Sections, top to bottom:
- Machine health: one row per Mac, showing the health of FM (Foundation Models, text and image) and OCR / Vision. The "Current state" columns show FM alive / dead / unknown (marked ● / ✕ / ?), the hardware video encoder (AVE = Apple Video Encoder) alive / dead / unknown (same marks; hover for the reason of a stop), the recent Vision call and failure counts, and CPU / MEM load. The "Period" columns come from run history, in the order things happen: runs, slowdowns caused by load, OCR / Vision notes, FM slot waits, FM call failures, skipped visibility checks and runs with FM dead (hover for breakdowns and reasons). Cells with failures or stops turn to a warning color. Values the monitor cannot observe, or that the records do not carry, show as "–" rather than 0. The "Period" columns count the run history of every test project, whichever project is selected
- Device health: one row per device, grouped by a Machine column. Shows the Device Monitor's current state (color-coded) and storage usage alongside counts from run history (excluded from run, requeued, pre-run exclude/repair, recovery operations, app crashes). Missing values show as "–". While "Show active devices" is on (the default), devices that are not started or not seen by the monitor are hidden. Storage usage is never measured automatically — all running virtual devices are measured only when you click Refresh storage (physical devices are not measured). Values measured before the monitor started are shown in gray until remeasured
- Latest run: scenarios newly failing and scenarios recovered since the previous run of the same profile
- Recent runs: click a row to open run detail; a failed step's file:line opens that line in the editor.
The "All / Performance runs only" toggle lists only runs made with
--performance. Check 2 rows at the left edge to compare their per-scenario durations (the earlier run is the baseline; only scenarios that passed in both are listed, largest slowdown first; a note appears when the 2 runs differ in profile or machine) - ⚠ Notable Issues (insights): grouped by severity, collapsed when 4 or more of the same kind appear
- Flaky Scenarios (last 10 runs) and scenario history
- Slow Tests (last 10 runs)
- Scenario Summary (last 10 runs): filterable by scenario ID, a "failures only" checkbox, sortable by clicking column headers
A toolbar control switches the aggregation period (last 5/10 minutes, 1/3/8/16 hours, or 1/2/3/7/30/90 days; the default is the last 16 hours, and the period you pick is remembered). Machine health and device health are always shown, even when the period has no runs. Refreshing keeps the current view visible while it re-fetches in the background.
Rerunning Failures and Reports
- "Rerun Failed Tests" re-runs only the scenarios that failed last time.
- "Open Report" opens the Markdown report for a scenario's last run (element list, screenshot, and — when available — self-healing suggestions).
- The Test Explorer toolbar's "Show Failed Tests Only" filter narrows the tree to failed tests.
Self-healing
Selector self-healing (fingerprint matching) follows the run profile's heal (on by default). Setting fleetest.heal to true adds --set heal=true to Run (not Run (dry-run)) and Debug, turning it on even when the profile says heal: false. When a run produces fix suggestions, it writes the fixed
selectors back to the scenario sources at the end and shows a notification. "Show Changes" opens
VSCode's Source Control view; review the git diff and commit. Anything that could not be written back
is listed in the execution log (see Self-healing).
Update Check
The Settings tab's "Updates" section is the one place updates are checked and applied:
- "Check for updates" reports whether the tool is up to date, a new release is available, the repo is version-pinned, or the check failed — read-only, no repository changes. When a new release is available it says "A new release X.Y.Z is available (current A.B.C)", and the "What's changed" button shows that release's notes in OUTPUT.
- "Update now" appears next to the tab only when an update is available; it switches to the latest release, rebuilds, and reinstalls the extension, then prompts to reload the window.
- Command "fleetest: Check for Updates" (
fleetest.checkForUpdate) always returns a result even when the once-a-day interval, a dismissed version, orfleetest.updateCheck: offwould otherwise silence the automatic check.
fleetest.updateCheck (auto/off) controls the automatic once-a-day startup check, which only
reads git ls-remote and never modifies the repository.
Display Language
fleetest.language (auto/ja/en) controls the extension's own UI text. auto follows VS
Code's display language. You can also switch it from "Display Language" in the Settings tab.
The installer (Scripts/install.sh) writes ja to your VSCode user settings when the macOS language is
Japanese, and en otherwise. It leaves fleetest.language untouched if you have already set it.
Cleaning Up Logs and Recordings
Recordings, reports, and logs pile up with every run, so each category has a size limit and the
oldest files are deleted first. The controls are in the Settings tab's "Logs & recordings"
section. They are stored as this Mac's settings (fleetest api retention), not VSCode
settings, so they also apply to tests you run directly from a terminal.
-
"Clean up in the background after a test run" (on by default): cleanup runs in the background after each test run. It does not count toward the test run time.
-
Limits: only a category whose usage reaches 90% of its limit is trimmed, oldest first, back down to 90%. Clearing a field resets just that item to its default (the default is shown faintly in the field). A value below the minimum becomes the minimum.
Item Default limit Minimum Device recordings and screenshots 2 GB 1 GB Recordings 50 GB 2 GB Reports 2000 MB 100 MB Logs 100 MB 10 MB Run logs ( *.ndjson)2 GB 100 MB Bridge diagnostics 5 GB 1 GB -
Each row shows the current usage on its right. Measuring takes about 20 seconds; until then it reads "Now - GB".
-
"Clean up now": deletes right away using the same rule. Before deleting, a confirmation dialog shows the total that will be removed.
-
Result records (the pass/fail and timing JSON) are never deleted.
-
Bridge diagnostics of a running bridge can't be deleted. So when this category goes over its limit, a bridge that no test, MCP session, or Live Control is using is rebuilt automatically and its old log is removed (that device's screen pauses for tens of seconds meanwhile). Turning off "Clean up in the background after a test run" also turns this off.
-
Reports are also cleaned up in the output folder a run profile sets with
reportDir. A folder given once with the command's--report-diris not cleaned up.
iOS Simulator wallpaper cache (CLI only)
iOS 27 Simulators accumulate cache with repeated boots, and a single Simulator can reach tens of GB. fleetest purges a Simulator's cache automatically right before it boots that Simulator (wallpaper settings and other data are left untouched).
To purge the Simulators that are not running in one go, run fleetest clean --simulator-poster-cache
from a terminal (--dry-run shows the amount without deleting). It purges every stopped
Simulator on this Mac and skips booted ones, naming them in the output. This isn't part of the
categories above or the Settings tab.
Key Settings
| Setting | Default | Description |
|---|---|---|
fleetest.binaryPath |
.build/debug/fleetest |
Path to the fleetest binary; falls back to PATH if not found |
fleetest.project |
"" |
Test project name; auto-resolved when empty (the only project, or project1 when there are several) |
fleetest.profile |
"" |
Run profile name; when set, it decides devices/app instead of fleetest.platform/port/serial |
fleetest.heal |
false |
true forces self-healing on regardless of the profile (false follows the profile's heal, which defaults to on; fixed selectors are written back to the scenarios) |
fleetest.buildBeforeRun |
true |
Build the Swift project before each run |
fleetest.lptScheduling |
true |
Schedule longer-running scenarios first (LPT), using recent run history |
fleetest.monitorInterval |
2 |
Device Monitor polling interval, in seconds |
fleetest.language |
"auto" |
Extension UI display language |
fleetest.updateCheck |
"auto" |
Automatic once-a-day update check on startup |