Expand description
§TestProvider (Environment)
TestController impl for MountainEnvironment. Hosts the
controller registry and routes test runs through proxied sidecars
(extension-provided test frameworks). Native Rust controllers are
not yet supported - they short-circuit to Skipped.
Layout (one export per file, file name = identity):
TestControllerState::Struct- per-controller registration.TestRunStatus::Enum- Queued / Running / Passed / Failed / Skipped / Errored.TestResult::Struct- per-test outcome.TestRun::Struct- active test run record.TestProviderState::Struct- aggregate controller + active-runs map, held insideApplicationStatebehind aRwLock.
The trait impl TestController for MountainEnvironment and its
private helpers stay in this parent file; they are dispatched via
the trait, not directly addressable, so they don’t need atomic
split for navigability.
VS Code reference:
vs/workbench/contrib/testing/common/testService.ts,vs/workbench/contrib/testing/common/testTypes.ts.
Modules§
- Test
Controller State - Per-controller registration record. Carries the extension-provided
identifier, label, owning sidecar, active flag, and supported test
type tags. Stored in
TestProviderState::Structkeyed byControllerIdentifier. - Test
Provider State - Aggregate state for the TestProvider: registered controllers and
currently active test runs. Held inside
ApplicationStatebehind atokio::sync::RwLockfor concurrent reads during test runs. - Test
Result - Per-test outcome: identifier, fully-qualified name, status, optional duration in ms, and optional error/stack-trace pair populated on failures.
- TestRun
- Active test run record: run identifier, owning controller, current
status, start instant, and per-test results keyed by test
identifier. Stored in
TestProviderState::Struct::ActiveRunsfor the duration of the run. - Test
RunStatus - Lifecycle state of a test run: Queued → Running → terminal (Passed / Failed / Skipped / Errored). Used both as the run-level aggregate and the per-test-result status.