# Build and test ## Prerequisites - Windows x64, .NET SDK 10.0.402 with its approved .NET 10 patch roll-forward. - Windows SDK target 10.0.26100.0 and MAUI Windows workload manifest 10.0.110. - Microsoft Edge WebView2 Runtime to launch the native Blazor Hybrid Client. The previously verified environment reported runtime 10.0.13, MAUI workload version 10.0.403 as listed by the installed SDK, and WebView2 Runtime 155.0.4283.62. The Client targets `net10.0-windows10.0.26100.0` and `win-x64`. All other projects target portable `net10.0`; tests do not require MAUI or WebView2. ## Restore, build, test and launch From the repository root in PowerShell, run the full build and both suites sequentially: ```powershell dotnet restore .\src\AutoForge.slnx dotnet build .\src\AutoForge.slnx --configuration Release --no-restore dotnet test .\src\AutoForge.slnx --configuration Release --no-build dotnet run --project .\src\AutoForge.Client\AutoForge.Client.csproj --configuration Release --framework net10.0-windows10.0.26100.0 ``` The build includes the actual native Client and all nine solution projects. For an explicit Windows runtime pack restore or direct native build: ```powershell dotnet restore .\src\AutoForge.Client\AutoForge.Client.csproj --runtime win-x64 dotnet build .\src\AutoForge.Client\AutoForge.Client.csproj --configuration Release --framework net10.0-windows10.0.26100.0 --no-restore ``` Do not pass Windows TFM overrides to the portable test projects. The Client contains the real UI RCL in a native MAUI BlazorWebView. No automotive driver, actual vehicle, database, backend, model or cloud account is required. ## Focused tests ```powershell dotnet test .\src\tests\AutoForge.UnitTests\AutoForge.UnitTests.csproj --configuration Release dotnet test .\src\tests\AutoForge.IntegrationTests\AutoForge.IntegrationTests.csproj --configuration Release ``` The unit suite covers existing Core/Application behavior, rendered generic components, profile invariants and strict codec behavior, plus protocol v1 round-trip/snapshot contracts and bounded trace behavior. The integration suite loads source-controlled profile fixtures through real DI, opens actual simulation sessions, sends/decodes requests through the transport, verifies identity/DTC/static signals, virtual clear/readback/reset and independent session state, exercises deterministic malformed/no-response/timeout/cancelled faults, renders the diagnostic route against the actual provider, and checks the nine-project reference graph. Fixtures are never treated as real vehicle definitions. The internal state oracle is exposed only to the integration-test assembly. The accepted Step-02A baseline was 103 unit plus 37 integration tests (140 total). The Step-03 worker report records the full, expanded counts, warnings, commands and native observations; do not infer acceptance from these earlier runs. Historical Step-02 had 59 unit and 34 integration cases; it predates the Step-02A corrections. See the [Step-02 report](../prompts/Step-02-Report.md) and [Step-02A report](../prompts/Step-02A-Report.md) for historical evidence. Step-03 worker verification ran the nine-project Release build with zero warnings/errors, then passed 108 unit and 53 integration cases (161 total, zero failed/skipped). Its native smoke used the actual Windows Client and verified explicit synthetic selection, module probes/identity, DTC and static signals, raw request/reply trace, virtual clear/readback/reset, close, target metadata, profile, home and not-found routes. Exact observations and limitations are recorded in the [Step-03 worker report](../prompts/Step-03-Report.md); the run did not cover the subsequently identified integrity findings and Step-03 was not accepted. Step-03A added actual failing-before/passing-after regressions for missing and duplicate request fields, semantic response validation/trace consistency, and clear acknowledgement versus verified readback. The final sequential Release verification passed 111 unit tests and 64 integration tests (175 total, zero failed/skipped), preserving the original 161 cases plus 14 additional test cases. Exact commands and outcome details are in the [Step-03A corrective report](../prompts/Step-03A-Report.md). Manual orchestrator acceptance remains pending. Step-03B reproduced the probe-only identity-loss defect before the fix through the real Simulation transport: the regression expected a positive probe but observed a negative discovery outcome. After the correction, the focused protocol/UI integration selection passed 35 cases. The complete nine-project Release build passed with zero warnings and errors, and the complete suite passed 111 unit plus 72 integration tests (183 total, zero failed/skipped), preserving all 175 Step-03A cases. Exact commands and AC mapping are recorded in the [Step-03B corrective report](../prompts/Step-03B-Report.md). The native Windows Client was launched and the operational baseline was exercised in its own WebView: explicit example import/profile/revision/provider/ Simulation selection, session open, discovery with expected/probe/identity counts, configured transmission no-response, engine DTC/static-signal reads, verified clear with fresh empty readback, raw/decoded trace, reset with initial DTC restoration, close, and `/execution-targets`, `/vehicle-profiles`, `/`, and not-found routes. Exact observations and limitations are in the [Step-03B corrective report](../prompts/Step-03B-Report.md). Native interaction used a session-local WebView debug port on the worker-launched Client; partial identity remains covered by real-DI rendered tests because the shipped native configuration has no fault selector for that scenario. ## Native synthetic diagnostics smoke Launch the actual Windows Client and visit `/diagnostics`: 1. Confirm the page starts without selecting/importing a profile or opening a session. Click **Load synthetic truck example**; verify the profile appears as an available revision but remains unselected. 2. Explicitly select `autoforge.synthetic.test-truck`, revision `1`, provider `autoforge.simulation.synthetic`, and kind `Simulation`. Click **Open simulation session** and confirm the visible session/profile/provider/ configuration identity. The session opens in process only. 3. Click **Probe virtual modules**. Engine/body respond; the configured transmission endpoint visibly reports no response and is not reported as an actual responder. Inspect the identity and declared implemented services. 4. Read the engine's DTCs and static signals. Values are synthetic static snapshots with source, unit, quality and logical tick. Expand the bounded trace to inspect actual request/response JSON and correlation values. 5. Clear the supported engine virtual DTCs, confirm the fresh readback is empty, and confirm the UI explicitly states that no physical write occurred. Other module/session state is isolated. 6. Exercise a visible deterministic failure (for example the configured transmission no-response), then reset to the initial synthetic state and close the session. Closing releases that session's trace and virtual state. 7. Separately visit `/execution-targets`, `/vehicle-profiles`, `/`, and an unmatched route. Confirm metadata selection remains separate from an operational session and the not-found/navigation behavior remains. The Step-03A report records actual native baseline smoke separately from headless rendered fault tests. The native Client revalidated explicit profile/provider selection, successful clear with fresh empty readback, trace/raw frames, visible no-response, reset/initial-state restoration, close and existing routes. A deliberately false clear acknowledgement was injected only in the rendered integration composition; the production Client has no UI fault selector, so this is not native fault-injection evidence. ## Profile-schema and safety boundaries See the [schema-v1 guide](vehicle-profile-schema-v1.md) for field, identity, unknown-value, capability, provenance and strict JSON rules. Important invariants: - Every v1 field is required; unknown optional facts are explicit JSON `null`. Unknown fields and duplicate/case-ambiguous properties are rejected. - Catalog selection requires exact `(profileIdentifier, revision)`. Duplicate imports do not replace entries, and failed parsing cannot partially register. - `publishedAt`/`retrievedAt` accept null or complete `YYYY-MM-DDTHH:mm:ss[.fraction](Z|+HH:mm|-HH:mm)` timestamps only. The exact fractional and offset limits and no-default policy are in the schema guide. - A null optional module identity in evidence is an absent constraint. Any supplied identity must match a known module value; an unknown target or mismatch is rejected without identity inference. - Imported profiles and capability/provenance statements are immutable metadata, not connection, compatibility, a working service or authorization. - Data remains in memory for the process only. JSON import/export does not write files or timestamps implicitly. - Simulation uses the separate [synthetic protocol](synthetic-diagnostics-v1.md) and [definition guide](simulation.md). It is not a real vehicle adapter, dynamics model, telemetry capture, replay provider, calibration/firmware editor or hardware write path.