/unreal-dev:unreal-automation-testsfrom unreal-dev
Guides writing and running Unreal Engine C++ automation tests (IMPLEMENT_SIMPLE_AUTOMATION_TEST, Automation Spec) and interpreting the JSON report for pass/fail verdicts.
Ships in unreal-dev. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
The engine's automation framework runs C++ tests inside the editor; run headless with a report folder, it leaves a JSON report and a few fixed log lines, and those two decide the verdict. The process exit code does not: a filter that matched nothing and a crash before the first test both end quietly.
| The situation | Read |
|---|---|
| "Add a test for this rule", a first test in the project | The method below, templates/RouteMathTest.cpp |
| Simple, complex or spec; flags; assertions; latent commands | reference/writing-tests.md |
| Many cases from data (one per map, one per parcel kind) | reference/writing-tests.md §3 |
| Describe / It / BeforeEach, a case that waits for something | reference/writing-tests.md §4–5, templates/RouteMath.spec.cpp |
| Run tests headless; filters; groups; exclusions; resume after a crash | reference/running-tests.md |
| Did the run pass? A report folder or a log to judge | reference/reading-results.md, scripts/test_report.py |
| Zero tests ran, a test never completed, report and log disagree | reference/reading-results.md §5, reference/writing-tests.md §6 |
| Building the editor target before a run | unreal-compile-loop |
| Starting the editor headless under a timeout | unreal-editor-python |
Put the rule in plain C++. templates/RouteMath.h and RouteMath.cpp: a struct of static
functions on plain data (FRouteMath::RouteLength). A rule that lives only in an actor's tick
needs a map and frames to test; move it out first.
Write the test in the module's Private/Tests/: templates/RouteMathTest.cpp (one
IMPLEMENT_SIMPLE_AUTOMATION_TEST whose RunTest returns every check's result) or
templates/RouteMath.spec.cpp (BEGIN_DEFINE_SPEC, Describe, It). Name it by dot path,
CourierRun.RouteMath.Length, and give it EAutomationTestFlags::EditorContext so a headless
editor can run it.
Build the editor target (unreal-compile-loop). A test added after the last build does not
exist in the run.
Run it headless with a fresh report folder, through the runner in unreal-editor-python:
UnrealEditor-Cmd.exe "C:/Work/CourierRun/CourierRun.uproject" \
-ExecCmds="Automation RunTest CourierRun.RouteMath;Quit" \
-ReportExportPath="C:/Work/CourierRun/Saved/TestReports/route" \
-unattended -nullrhi -nosplash -stdout -FullStdOutLogOutput
Judge it from the report and the log:
python3 scripts/test_report.py --report "C:/Work/CourierRun/Saved/TestReports/route" \
--log run.log --require CourierRun.RouteMath.Length
test_report: PASS 4 passed, 0 failed, 0 skipped; report .../route/<report>.json, log run.log
| Exit | Verdict | When |
|---|---|---|
| 0 | PASS | tests ran (at least --min-tests), every one Success, the log reached **** TEST COMPLETE. EXIT CODE: 0 ****, every --require test passed |
| 2 | FAIL | a failed test; zero tests ran; a test that started and never completed; inProcess or notRun in the report; no closing EXIT CODE line, or a non-zero one; a Fatal line; report and log disagreeing |
| 3 | UNVERIFIED | nothing readable: no report under the folder and no usable log, or a log without one automation line |
| 1 | usage | neither --report nor --log, a bad flag |
A Skipped test (an exclusion in config) is listed and not counted as run.
EditorContext all give a clean, empty run.Test* call logs its own error and returns whether it held; have
RunTest return their conjunction, so the verdict never rests on one line.RunTest returns. A check written below
ADD_LATENT_AUTOMATION_COMMAND runs before the map loads; put it inside a command's Update()
or a LatentIt.LatentIt that never calls Done.Execute() holds the run until
the outside timeout; the report then shows a test in progress.-nullrhi has no rendering device. A test flagged NonNullRHI needs one: run it without
-nullrhi.--require line together, or
the renamed test fails CI as absent.unreal-compile-loop → reference/build-commands.md: building the editor target the tests run inunreal-editor-python → reference/headless-runs.md: the headless run, its timeout and its sentinelunreal-config-logs → reference/logging.md: the log and its categories; the crash folderunreal-project → reference/engine-discovery.md: finding the binary and the project's modules firstreference/reading-results.md (opens in a new tab)reference/running-tests.md (opens in a new tab)reference/writing-tests.md (opens in a new tab)scripts/test_report.py (opens in a new tab)templates/RouteMath.cpp (opens in a new tab)templates/RouteMath.h (opens in a new tab)templates/RouteMath.spec.cpp (opens in a new tab)templates/RouteMathTest.cpp (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Other plugins' skills for the same job
17 skills in this plugin
/unreal-animationUnreal animation: Animation Blueprint or C++ UAnimInstance, NativeUpdateAnimation, montages, slots, sections, notifies and notify states, root motion./unreal-asset-importImport meshes, textures and animation into Unreal by script: AssetImportTask, Interchange pipelines, glTF and FBX options, static or skeletal mesh, budget check./unreal-blueprint-boundarySplit Unreal work between C++ and Blueprint: BlueprintCallable, BlueprintNativeEvent, BlueprintImplementableEvent, exposed properties, data assets, soft references./unreal-compile-loopCompile Unreal C++ from a terminal: target, platform and configuration, UnrealBuildTool and compiler errors, Live Coding or a closed-editor rebuild./unreal-config-logsUnreal config and logs: Default*.ini layering, [/Script/...] sections, console variables, UE_LOG categories and verbosity, Saved/Logs, Saved/Crashes./unreal-cpp-reflectionUnreal C++ reflection: UCLASS, UPROPERTY, UFUNCTION, USTRUCT, UENUM, GENERATED_BODY, specifiers, TObjectPtr, garbage collection; a header lint.npx claudepluginhub tipoli5890/game-studio --plugin unreal-dev