Member Junction
    Preparing search index...

    Test driver of the "Feature Pipeline Golden Set" test type. Evaluates the version the pipeline would run now (its current pin) on the test's golden cases and stores the result on that version through the version registry, which activates it when the result meets the threshold the pipeline's Activation declares, and refuses it otherwise.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    Metadata provider used by the driver for entity access. Set explicitly via the Provider setter; falls back to the global Metadata.Provider when not set. The engine (or test harness) should set this to thread a transaction-scoped provider.

    Accessors

    • get _metadata(): Metadata

      Returns Metadata

      Use _provider (IMetadataProvider) instead. Retained for backward compatibility with subclasses that referenced the previous _metadata: Metadata field directly. Returns the same underlying provider cast to the legacy Metadata shape.

    • get Provider(): IMetadataProvider

      The metadata provider this driver uses. Falls back to the global Metadata.Provider when the engine hasn't injected an explicit provider — multi-tenant servers should always set this so each driver run binds to the right database connection.

      Returns IMetadataProvider

    • set Provider(value: IMetadataProvider): void

      Parameters

      Returns void

    Methods

    • Protected

      Calculate overall score from oracle results.

      If weights are provided, calculates weighted average. Otherwise, calculates simple average.

      Parameters

      • oracleResults: OracleResult[]

        Results from oracle evaluations

      • Optionalweights: ScoringWeights

        Optional scoring weights by oracle type

      Returns number

      Overall score from 0.0 to 1.0

    • Protected

      Create a log message for the test execution log.

      Parameters

      • level: "error" | "info" | "warn" | "debug"

        Log level

      • message: string

        Log message

      • Optionalmetadata: Record<string, unknown>

        Optional metadata

      Returns TestLogMessage

      TestLogMessage object

    • Protected

      Determine overall test status from oracle results.

      Test passes only if ALL oracles pass.

      Parameters

      • oracleResults: OracleResult[]

        Results from oracle evaluations

      Returns "Failed" | "Passed"

      'Passed' if all oracles passed, 'Failed' otherwise

    • Protected

      Get the effective timeout for a test.

      Priority (highest to lowest):

      1. Configuration JSON maxExecutionTime field (backward compatibility)
      2. Test.MaxExecutionTimeMS column
      3. DEFAULT_TEST_TIMEOUT_MS constant (5 minutes)

      Parameters

      • test: MJTestEntity

        The test entity

      • Optionalconfig: { maxExecutionTime?: number }

        Parsed configuration object (optional)

      Returns number

      Timeout in milliseconds

    • Protected

      Log execution progress.

      Parameters

      • message: string

        Log message

      • OptionalverboseOnly: boolean

        Whether to only log in verbose mode (default: false)

      Returns void

    • Protected

      Log errors.

      Parameters

      • message: string

        Error message

      • Optionalerror: Error

        Optional error object

      Returns void

    • Protected

      Log a message to both the console (if verbose) and accumulate for test run log.

      Parameters

      • context: DriverExecutionContext

        Driver execution context

      • level: "error" | "info" | "warn" | "debug"

        Log level

      • message: string

        Log message

      • Optionalmetadata: Record<string, unknown>

        Optional metadata

      Returns void

    • Protected

      Parse and validate Configuration JSON.

      Helper method for drivers to parse their configuration with type safety. Throws if configuration is invalid.

      Type Parameters

      • T

        The configuration type

      Parameters

      Returns T

      Parsed configuration

      Error if configuration is missing or invalid

    • Protected

      Parse and validate ExpectedOutcomes JSON.

      Type Parameters

      • T

        The expected outcomes type

      Parameters

      • test: MJTestEntity

        The test containing the expected outcomes

      Returns T

      Parsed expected outcomes

      Error if expected outcomes is missing or invalid

    • Protected

      Parse and validate InputDefinition JSON.

      Type Parameters

      • T

        The input definition type

      Parameters

      Returns T

      Parsed input definition

      Error if input definition is missing or invalid

    • Parameters

      Returns void

      Use the Provider setter instead. Retained for backward compatibility.

    • Suite-scoped setup. Runs ONCE after the suite run is created and before the first test's Execute, when the test runs inside a suite (mj test suite). Provision suite-shared fixtures here — discover/create users, create Query/Category rows, refresh engine caches — and stash them on context.Data / context.CreatedRecords so every Execute of the suite (which receives this same context via DriverExecutionContext.fixtures) can read them, and TeardownSuite can clean them up.

      Default is a no-op, so existing drivers (AgentEval, Computer Use) are unaffected. Does NOT fire for the standalone mj test run path (no suite).

      Parameters

      Returns Promise<void>

    • Whether this driver supports cancellation via AbortSignal.

      Drivers should override this to return true if they properly handle cancellation tokens. When a driver doesn't support cancellation, timeout will still mark the test as failed but the underlying execution may continue in the background.

      Returns boolean

      true if driver supports cancellation, false otherwise

    • Suite-scoped teardown. GUARANTEED by TestEngine.RunSuite via a finally, so it runs on pass, fail, a thrown Execute, and after a 'Timeout' result. MUST be best-effort: never throw (the engine logs and ignores any throw), only clean up. Delete what SetupSuite created (the context.CreatedRecords list and any driver-specific payload under context.Data).

      Default is a no-op. Does NOT fire for the standalone mj test run path.

      Parameters

      Returns Promise<void>

    • Validate test configuration.

      Called when creating or updating a test to ensure the configuration is valid for this test type. Override to add type-specific validation.

      Parameters

      Returns Promise<ValidationResult>

      Validation result with errors and warnings