The loader smoke test boots an application fixture from its real entry point and configuration, inside an isolated temporary folder, and then drives exactly one task through the fixture's single top-level agent. Use it for keyless smoke tests that must prove the real boot path. To choose between the test tiers, see Testing tiers.
A run starts the fixture's own entry point as a child process, hands it the fixture's configuration and arguments, and reports what happened.
| Option | What it sets |
|---|---|
label | The name the fixture is reported under in failures. |
tempDirPrefix | A prefix for the name of the temporary folder the smoke test creates. |
binScript | The fixture's entry point to launch. |
configPath | The fixture's configuration file. |
tsconfigPath | The TypeScript project that supplies source mode's workspace path map. |
sourceImport | How source files are imported in source mode (tsx/). |
expectedExitCode | The exit code the run must end with; 0 unless you declare another. |
src is the default and runs the fixture from source; lib runs the built output. Any other value stops the launch: must be 'src' or 'lib', got <value>.tsconfigPath; without it the launch stops: 'src' mode needs tsconfigPath for the workspace paths map.pnpm run build first (Building and shipping Oda). Built mode runs the built files, with no source loader and no path map./ src/ segment of the entry path (or the \src\ equivalent on Windows) to find the built file. A path with no such segment stops the launch: expected a "/ src/ " segment or Windows equivalent in bin path <path>. Pass the built entry point explicitly (libBin) when your layout has no such segment.runFixtureTurn drives exactly one task through the fixture's single top-level agent. It waits for the fixture to publish its first agent before counting, so a fixture that creates its agent late is fine; after the wait, the count must be exactly one.{ type: 'result', sessionId, output, usage? }. sessionId names the session, output is the run's final output, and usage totals the token counts reported per turn and step. usage is left out when the recorded stretch reports none.must be 'src' or 'lib', got <value>. The mode environment variable received a value that is not src or lib. Set it to one of the two, or leave it unset for source mode.'src' mode needs tsconfigPath for the workspace paths map. Source mode cannot resolve workspace imports without the path map. Pass your TypeScript project as tsconfigPath.expected a "/ src/ " segment or Windows equivalent in bin path <path>. The built entry point cannot be derived from that path. Give the path a / src/ segment, or pass the built entry point explicitly (libBin).<label> did not exit within <s>s. The child outlived its deadline and was killed; the message carries the captured standard output and standard error.<label> exited <code> (expected <code>). The child ended with a code the run did not expect, in either direction; the captured output is attached. Declare expectedExitCode when the fixture is meant to end with another code.fixture turn requires exactly one top-level agent, found <N>. The fixture published no top-level agent (found 0) or more than one. Give it exactly one.runFixtureTurn drives a single task; call it again for another turn.When a test must prove the real boot path: the fixture starts from its real entry point and configuration, and one task runs through its top-level agent with no model key. To pick between the tiers, see Testing tiers.
Set the mode environment variable to lib, and build the project first with pnpm run build (Building and shipping Oda). Source mode is the default when the mode is unset.
Source mode resolves workspace imports through the path map of the TypeScript project you pass as tsconfigPath. Without it the launch stops with 'src' mode needs tsconfigPath for the workspace paths map.
Built mode derives the built entry point by rewriting the last / segment of the entry path (or the \src\ equivalent on Windows). A path with no such segment stops with expected a "/. Pass the built entry point explicitly (libBin) when your layout has no such segment.
No. The child runs in a temporary folder the smoke test creates, with the fixture's home folders inside it. The smoke test removes only a folder it created; a folder you pass yourself is reused and left in place.
It is killed at its deadline, 30 seconds by default, and the run fails with did not exit within <s>s plus the captured output. The deadline ends the direct child only, so a process the fixture started can outlive the run.
The child ended with a code the run did not expect, in either direction: a nonzero exit where 0 was expected, or a clean exit where another code was declared. Declare expectedExitCode when the fixture is meant to end with a nonzero code. The message names both codes and attaches the captured output.
The driver drives exactly one top-level agent. found 0 means no agent appeared, most often because the fixture registers no agents service; found <N> means the fixture published more than one. The driver waits for the first agent publication before counting, so a fixture that creates its agent late is fine.
The result envelope { type: 'result', sessionId, output, usage? }: the session id, the run's final output, and the usage collected per turn and step. usage is left out when the recorded stretch reports none.
Yours, with two changes: proxy settings are cleared, so a call to a fixture server is never sent through a proxy, and the fixture's home folders point inside its temporary folder. Standard input is closed at once.